Skip to main content

Manage project semantic version.

Project description

Semversion

Python Semantic Versioning Tool

Open in Dev Containers Code style: black Test Lint Deploy to PyPI Deploy to PyPI Test

semversion is a Python module designed to manage and easily modify semantic versions of your projects. With this tool, you can keep a version log and update it as needed.

Installation

You can install semversion using pip:

$ pip install semversion

Running this command for the first time promts for the creation of the .version file if it doesnt exists.

Version file can be modified using envirment variable SEMVERSION_FILE

Basic Usage

semversion can be used as a standalone python module, mainly for scripting.

$ python -m semversion <version_part>

Example Usage

from semversion import version, increment, initialize, SEMVERSION_FILE, MAJOR, MINOR, PATCH

# Get the current version
current_version = version()
print(f"Current version: {current_version}")

# Increment the minor version
new_version = increment(MINOR)
print(f"New version: {new_version}")

Contribute

Feel free to contribute! Open an issue or send a pull request.

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

semversion-2.0.3.tar.gz (3.7 kB view hashes)

Uploaded Source

Built Distribution

semversion-2.0.3-py3-none-any.whl (5.4 kB view hashes)

Uploaded Python 3

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