fish-shell/fish-rust
Henrik Hørlück Berg e7f8fb04cc Add BUILD_VERSION to lib.rs
In CMake this used a `version` file in the CARGO_MANIFEST_DIR, but
relying on that is problematic due to change-detection, as if we add
`cargo-rerun-if-changed:version`, cargo would rerun every time if the file does
not exist, since cargo would expect the file to be generated by the
build-script. We could generate it, but that relies on the output of `git
describe`, whose dependencies we can only limit to anything in the
`.git`-folder, again causing unnecessary build-script runs.

Instead, this reads the `FISH_BUILD_VERSION`-env-variable at compile time
instead of the `version`-file, and falls back to calling git-describe through
the `git_version`-proc-macro. We thus do not need to deal with extraneous
build-script running.
2023-09-05 11:38:59 +02:00
..
src Add BUILD_VERSION to lib.rs 2023-09-05 11:38:59 +02:00
widestring-suffix Move edition and MSRV to workspace 2023-08-19 15:18:38 +02:00
build.rs Add BUILD_VERSION to lib.rs 2023-09-05 11:38:59 +02:00