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.2.tar.gz (17.6 kB view details)

Uploaded Source

Built Distribution

get_version-3.2-py3-none-any.whl (16.2 kB view details)

Uploaded Python 3

File details

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

File metadata

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

File hashes

Hashes for get_version-3.2.tar.gz
Algorithm Hash digest
SHA256 b01a7d84d60a4839d035375151ae03b9ee902baa503effb0cf8ccd6d4d79aa1d
MD5 802bc065f72a47de1672205666dbe44c
BLAKE2b-256 03772d11cec1072f53687adf932ebd75ea5d545d51fe6475668f2850fe1b192c

See more details on using hashes here.

File details

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

File metadata

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

File hashes

Hashes for get_version-3.2-py3-none-any.whl
Algorithm Hash digest
SHA256 0da384db12fa61ea25067b576b47bf83d539f30e14f3e44f4fe8b59b1656b708
MD5 0183324381ec3aa49f3ef53d2c438428
BLAKE2b-256 2eeb4892cfbc7a3275306f41b74dd86e516041e58b67d1daa30c44861a6f0510

See more details on using hashes here.

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