Simple generator used for cmake/make build systems. This does not create any symlinks. It requires the build system to build unconditionally. Args: output_file: Output filename for the version info cc source_dir: Base path of the source code git_tag_override: Override the value f
(output_file, source_dir, git_tag_override=None)
| 267 | |
| 268 | |
| 269 | def raw_generate(output_file, source_dir, git_tag_override=None): |
| 270 | """Simple generator used for cmake/make build systems. |
| 271 | |
| 272 | This does not create any symlinks. It requires the build system |
| 273 | to build unconditionally. |
| 274 | |
| 275 | Args: |
| 276 | output_file: Output filename for the version info cc |
| 277 | source_dir: Base path of the source code |
| 278 | git_tag_override: Override the value for the git tag. This is useful for |
| 279 | releases where we want to build the release before the git tag is |
| 280 | created. |
| 281 | """ |
| 282 | |
| 283 | git_version = get_git_version(source_dir, git_tag_override) |
| 284 | write_version_info(output_file, git_version) |
| 285 | |
| 286 | |
| 287 | parser = argparse.ArgumentParser(description="""Git hash injection into bazel. |
no test coverage detected