Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Remove semver bumping from release-tag-version workflow #90

Open
yannick-roeder opened this issue Apr 6, 2023 · 0 comments · May be fixed by #136
Open

Remove semver bumping from release-tag-version workflow #90

yannick-roeder opened this issue Apr 6, 2023 · 0 comments · May be fixed by #136
Assignees

Comments

@yannick-roeder
Copy link
Member

yannick-roeder commented Apr 6, 2023

We should be able to use this configuration for bumpversion to properly work with a -snapshot suffix without the need for semver:

[bumpversion]
current_version = 0.2.2-snapshot
search = version: {current_version}
replace = version: {new_version}
parse = (?P<major>\d+)\.(?P<minor>\d+)\.(?P<patch>\d+)(-(?P<release>snapshot))?
serialize = 
	{major}.{minor}.{patch}-{release}
	{major}.{minor}.{patch}

[bumpversion:part:release]
first_value = snapshot
optional_value = release
values = 
	snapshot
	release

Then bumpversion release always removes the suffix and bumpversion major, bumpversion minor and bumpversion patch always add it. In order to do a major or minor release 2 bumpversion commands can be chained then:

bumpversion release
bumpversion major/bumpversion minor
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants