semver-setuptools-git-version
Automatically set package version from Git. This is a re-release of better-setuptools-git-version with fixes and improvements for semver ordering, which is itself a re-release of setuptools-git-version
Introduction
Instead of hard-coding the package version in setup.py like:
setup(
name='foobar',
version='1.0',
...
)
this package allows to extract it from tags in the underlying Git repository:
setup(
name='foobar',
version_config={
"version_format": "{tag}.dev{sha}",
"starting_version": "0.1.0"
},
setup_requires=['semver-setuptools-git-version'],
...
)
The tool uses the semantically-latest tag as the base version. If there are no annotated tags, the version specified by starting_version will be used. If HEAD is at the tag, the version will be the tag itself. If there are commits ahead of the tag, the first 8 characters of the sha of the HEAD commit will be included.
In all the above cases, if the working tree is also dirty or contains untracked files, a +dirty suffix will be appended to the version.
Metadata
Release files for semver-setuptools-git-version 1.0.0
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| semver-setuptools-git-version-1.0.0.tar.gz | 2.4 kB | Without provenance | Details for semver-setuptools-git-version-1.0.0.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| semver_setuptools_git_version-1.0.0-py3-none-any.whl | Python 3 | none | any | Details for semver_setuptools_git_version-1.0.0-py3-none-any.whl |
Total release size: 5.9 kB
Release files / semver-setuptools-git-version-1.0.0.tar.gz
| Download URL | semver-setuptools-git-version-1.0.0.tar.gz |
|---|---|
| Size | 2.4 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
6bbe8e8a8a3b061371e50422f266589d4d0386406eb92e10e60c6de3a199f272
|
|
BLAKE2b-256 checksum How to use checksums |
10d95d8eea99f58290eaa757b6fb60e053b799adc91537fdbbec089e8731022d
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/3.7.1 importlib_metadata/4.0.1 pkginfo/1.8.2 requests/2.25.1 requests-toolbelt/0.9.1 tqdm/4.62.3 CPython/3.9.7
|
Release files / semver_setuptools_git_version-1.0.0-py3-none-any.whl
| Download URL | semver_setuptools_git_version-1.0.0-py3-none-any.whl |
|---|---|
| Size | 3.4 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
02786e205fd4e81b0f97d1dbb7bcb1db5ba054cdea72df26217fe573dec72de9
|
|
BLAKE2b-256 checksum How to use checksums |
3ee1e9ad4d1ca7cdfe63b4d06562b09fab6795985889cefe52dee2b21547ae32
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/3.7.1 importlib_metadata/4.0.1 pkginfo/1.8.2 requests/2.25.1 requests-toolbelt/0.9.1 tqdm/4.62.3 CPython/3.9.7
|
Security for semver-setuptools-git-version 1.0.0
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.