Releases: mtkennerly/dunamai
v1.5.1 (2020-12-16)
- Improved ordering of Git tags, particularly when commit dates were not chronological. (Contributed by mariusvniekerk)
- Improved Subversion handling when in a subdirectory of the repository. (Contributed by Spirotot)
v1.5.0 (2020-12-02)
- Added the
--tagged-metadata
option and corresponding attribute on theVersion
class. (Contributed by mariusvniekerk) - Added explicit dependency on setuptools (because of using
pkg_resources
) for environments where it is not installed by default.
v1.4.1 (2020-11-17)
- For Git, replaced
--porcelain=v1
with--porcelain
to maintain compatibility with older Git versions.
v1.4.0 (2020-11-17)
- Added the
--bump
command line option and thebump
argument toVersion.serialize()
. - Fixed an issue with Git annotated tag sorting. When there was a newer annotated tag A on an older commit and an older annotated tag B on a newer commit, Dunamai would choose tag A, but will now correctly choose tag B because the commit is newer.
- With Git, trigger the dirty flag when there are untracked files. (Contributed by jpc4242)
v1.3.1 (2020-09-27)
- Fixed ambiguous reference error when using Git if a tag and branch name were identical.
v1.3.0 (2020-07-04)
-
Previously, when there were not yet any version-like tags, the distance would be set to 0, so the only differentiator was the commit ID. Now, the distance will be set to the number of commits so far. For example:
- No commits: base = 0.0.0, distance = 0
- 1 commit, no tags: base = 0.0.0, distance = 1
- 10 commits, no tags: base = 0.0.0, distance = 10
v1.2.0 (2020-06-12)
- Added
--debug
flag in thefrom
command.
v1.1.0 (2020-03-22)
- Added these functions to the public API:
serialize_pep440
serialize_semver
serialize_pvp
bump_version
v1.0.0 (2019-10-26)
-
Changed the
Version
class to align with Dunamai's own semantics instead of PEP 440's semantics.Previously,
Version
implemented all of PEP 440's features, like epochs and dev releases, even though Dunamai itself did not use epochs (unless you created your ownVersion
instance with one and serialized it) and always set dev to 0 in thefrom_git
/etc methods. Theserialize
method then tried to generalize those PEP 440 concepts to other versioning schemes, as in0.1.0-epoch.1
for Semantic Versioning, even though that doesn't have an equivalent meaning in that scheme.Now, the
Version
class implements the semantics used by Dunamai, giving it more power in the serialization to map those concepts in an appropriate way for each scheme. For example,dev0
is now only added for PEP 440 (in order to be compatible with Pip's--pre
flag), butdev.0
is no longer added for Semantic Versioning because it served no purpose there.API changes:
post
has been renamed todistance
, and its type is simplyint
rather thanOptional[int]
epoch
anddev
have been removedpre_type
has been renamed tostage
pre_number
has been renamed torevision
, and it is no longer required when specifying a stage
-
Improved error reporting when the version control system cannot be detected and when a specified VCS is unavailable.
-
Improved the default regular expression for tags:
- It now requires a full match of the tag.
- It now recognizes when the
base
andstage
are separated by a hyphen. - It now recognizes when the
stage
andrevision
are separated by a dot. - It now allows a
stage
without arevision
.
v0.9.0 (2019-10-22)
- Added Fossil support.
- Fixed case with Git/Mercurial/Subversion/Bazaar where, if you checked out an older commit, then Dunamai would consider tags for commits both before and after the commit that was checked out. It now only considers tags for the checked out commit or one of its ancestors, making the results more deterministic.
- Changed VCS detection to be based on the result of VCS commands rather than looking for VCS-specific directories/files. This avoids the risk of false positives and simplifies cases with inconsistent VCS files (e.g., Fossil uses
.fslckout
on Linux and_FOSSIL_
on Windows)