-
Notifications
You must be signed in to change notification settings - Fork 96
Unable to create pre-release with an empty token #344
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
Comments
Thank you @vincent-herlemont, much appreciated. Sorry for the late response. I suppose, this should be fixed. This behaviour is the same for the method |
@vincent-herlemont One question. What would you expect if you have already a prerelease and pass an empty string? Like this:
I could think of two solutions:
If you already have a prerelease, you would like to continue when using In other words: If prerelease isn't set, the token is taken into account, otherwise it's ignored (regardless of the value). |
The methods .bump_prerelease('') and .bump_build('') generates a prerelease and build part without the token.
The methods .bump_prerelease('') and .bump_build('') generates a prerelease and build part without the token.
The methods .bump_prerelease('') and .bump_build('') generates a prerelease and build part without the token.
The methods .bump_prerelease('') and .bump_build('') generates a prerelease and build part without the token.
The methods .bump_prerelease('') and .bump_build('') generates a prerelease and build part without the token.
The methods .bump_prerelease('') and .bump_build('') generates a prerelease and build part without the token.
The methods .bump_prerelease('') and .bump_build('') generates a prerelease and build part without the token.
The methods .bump_prerelease() and .bump_build() allow now different types for the token argument: * A string. This was already allowed and default was "rc". If the string is empty, we get only the raised number (without the "rc" part). * None. Is the same as calling the method without any argument.
The methods .bump_prerelease() and .bump_build() allow now different types for the token argument: * A string. This was already allowed and default was "rc". If the string is empty, we get only the raised number (without the "rc" part). * None. Is the same as calling the method without any argument.
Fix #344 Allow empty string for bump method
Situation
Unable to create pre-release with an empty token.
To Reproduce
Run this script:
Expected Behavior
.bump_prerelease('')
should generate an version like1.0.0-1
.Environment
Additional context
Pre-release documentation https://semver.org/#spec-item-9
The text was updated successfully, but these errors were encountered: