Skip to main content

A version helper in the spirit of versioneer.

Project description

Automatically use the latest “vX.X.X” Git tag as version in your Python package.

It also supports getting the version from Python source distributions (sdist) or, once your package is installed, via importlib.metadata.

usage

Add the following into yourpackage.py (or __init__.py):

from get_version import get_version
__version__ = get_version(__file__)
del get_version

contributing

Use black . to ensure proper code style. In order to not forget you can use pre-commit install.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

get_version-3.5.4.tar.gz (19.5 kB view details)

Uploaded Source

Built Distribution

get_version-3.5.4-py3-none-any.whl (18.3 kB view details)

Uploaded Python 3

File details

Details for the file get_version-3.5.4.tar.gz.

File metadata

  • Download URL: get_version-3.5.4.tar.gz
  • Upload date:
  • Size: 19.5 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: python-requests/2.26.0

File hashes

Hashes for get_version-3.5.4.tar.gz
Algorithm Hash digest
SHA256 5901c846518d55d52c1f6f037f5d2433952b46bbf36e38c52f064ae836556343
MD5 164c51221bd5aa2281c59c68d48a05a4
BLAKE2b-256 02fdb212504343cdd6a15d3cf00c02f8e1aaf2b3ce0223736a3b1d239b4367e6

See more details on using hashes here.

Provenance

File details

Details for the file get_version-3.5.4-py3-none-any.whl.

File metadata

File hashes

Hashes for get_version-3.5.4-py3-none-any.whl
Algorithm Hash digest
SHA256 d49d9d897116ffcc1fac7773dea00d9de44ca1905b83955f3309bcd281cf063a
MD5 f6eebc59f1d47e5533162e759d603a66
BLAKE2b-256 f91a120c6885a7b31d6fbd29751543bd794eb6d6a854ab7f8293302a51f09998

See more details on using hashes here.

Provenance

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page