Skip to content

Latest commit

 

History

History
28 lines (20 loc) · 953 Bytes

README.rst

File metadata and controls

28 lines (20 loc) · 953 Bytes

semver_range

Python package for semantic versioning 2.0.0 that mimics the node semver package. The interface is designed to be more "pythonic" and does not match semver’s logic 100%.

Usage

Install using pip install semver_range. Sample usage:

>>> from semver_range import Version, Range
>>> version_range = Range('>=0.1.1 <0.3.0')
>>> Version('0.2.2') in version_range
True
>>> version_range.highest_version(['0.1.1', '0.2.0', '0.3.0'])
<Version "0.2.0">

Alternatives

semantic_version is a great package which differs slightly in its implementation of semantic versioning, for example when incrementing a minor version of a pre-release.