-
- Downloads
fix: Add at build time the git revion to version
Instead of having a hardcoded version, calculate the version at build time making use of `git describe --tags --dirty --always`. This way, even if the program is not running from inside a git repository it still can know which was the git revision from the source it was installed from. If the program is launched from a path that is a git repository, it does not gives the git revision of that other repository. If's also able to get the version when installed from a tarball. It does not add the git revision when it's being install from a git tag. `versioneer` external program is only needed the first time, because it copies itself into the repository. So it does not add an external dependency. There're no changes needed to the `--version` cli argument nor to the code that generates the bandwidth file, since they both use the variable `__version__`. The version previous to this commit was `1.1.1-dev0`, after this commit, it becomes `1.1.0+xx.gyyyyyyyy`, ie. xx commits after `1.1.0` plus the git short hash (yyyyyyyy). Closes: #30899.
Showing
- MANIFEST.in 1 addition, 0 deletionsMANIFEST.in
- sbws/__init__.py 3 additions, 1 deletionsbws/__init__.py
- sbws/_version.py 520 additions, 0 deletionssbws/_version.py
- setup.cfg 18 additions, 0 deletionssetup.cfg
- setup.py 5 additions, 9 deletionssetup.py
- versioneer.py 1822 additions, 0 deletionsversioneer.py
Loading
Please register or sign in to comment