Expand description
The version string proc --version prints.
main keeps the last released version number until the next release, so a
build from main would print the same 1.14.5 as the real 1.14.5. This
module names the commit for any build that is not the release tag itself.
build.rs compiles this file too (through #[path]): it gathers the git
facts, calls format_version and hands the result to the crate as
PROC_VERSION. The logic lives here, in the crate, so it is tested and
counted by the coverage gate; build.rs only runs git.
Structs§
- GitFacts
- What git says about the checkout a build is made from.
Functions§
- format_
version - The version to show.
package_versionis Cargo’s version;factsisNoneoutside a git checkout (crates.io packages, Docker contexts without.git), which gives the plain version.