Support PEP 440 version scheme

Allow specifying x.y.z.dev0

Now when we bump a minor it will automatically bump to dev.

current_version = 0.2.1
$ bumpversion patch
new_version = 0.2.2.dev0

If we want to release from any dev version:

$ bumpversion dev=4
This commit is contained in:
Gorka Eguileor
2018-07-04 19:11:05 +02:00
parent 38db760c9b
commit 65977d1dbe

View File

@@ -2,6 +2,10 @@
current_version = 0.2.1
commit = True
tag = True
parse = (?P<major>\d+)\.(?P<minor>\d+)\.(?P<patch>\d+)(?:\.dev(?P<dev>\d+))?
serialize =
{major}.{minor}.{patch}.dev{dev}
{major}.{minor}.{patch}
[bumpversion:file:setup.py]
search = version='{current_version}'
@@ -11,6 +15,15 @@ replace = version='{new_version}'
search = __version__ = '{current_version}'
replace = __version__ = '{new_version}'
[bumpversion:part:dev]
values =
0
1
2
3
4
optional_value = 4
[bdist_wheel]
universal = 1