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 pkg_resources (part of setuptools).

usage

Add setuptools to the dependencies of your package, and 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.0.tar.gz (17.5 kB view details)

Uploaded Source

Built Distribution

get_version-3.0-py3-none-any.whl (16.0 kB view details)

Uploaded Python 3

File details

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

File metadata

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

File hashes

Hashes for get_version-3.0.tar.gz
Algorithm Hash digest
SHA256 8ed79b3d28acc89ece9bff2bdf0e69b9f44f3aa3f43a317fba360f02810c07a5
MD5 cccd5db4d5972157c2f58491cd6fa93f
BLAKE2b-256 b54e4866138f4810caa5715aea56bea82ee58e09335a157e97214cb39deb0631

See more details on using hashes here.

Provenance

File details

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

File metadata

  • Download URL: get_version-3.0-py3-none-any.whl
  • Upload date:
  • Size: 16.0 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: python-requests/2.25.1

File hashes

Hashes for get_version-3.0-py3-none-any.whl
Algorithm Hash digest
SHA256 db2f31c281c41fba93f2546539a30c8d906f3d27fe2f8d229825e4292a671c93
MD5 def139db2213c4e922fefa5e2cf7aba4
BLAKE2b-256 d7b2e47643bb1418642070da5b60552b2042f1001aa5802dc0937f8de4997cbc

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