-
Notifications
You must be signed in to change notification settings - Fork 132
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
add support to keep values of specific parts (eg. metadata used in semver) #80 #81
base: master
Are you sure you want to change the base?
add support to keep values of specific parts (eg. metadata used in semver) #80 #81
Conversation
{major}.{minor}.{patch} | ||
|
||
[bumpversion:file:setup.py] | ||
[bumpversion:part:metadata] | ||
keep_value = True |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I would call this independent
, because the metadata
part can still change (if you change it explicitly).
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
hmm, I'm not sure if I would grok exactly what independent
means at a first glance. Changing it explicitly is out-of-scope of bumpversion and in the context of bumpversion keep_value: True
seems more straightforward.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I have to agree with @c4urself as I as well wouldn't know how to interpret independent
. But I am still open for other suggestions.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ok, now I see where this independent
actually comes from (ADVbumpversion). If you plan to merge both forks again I would be find with independent
.
Are there any plans to do that?
|
||
[bumpversion:file:bumpversion/__init__.py] | ||
#[bumpversion:file:setup.py] |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Beware, bump2version will remove these commented lines on the next bump!
Related issue: #80 |
I've just discovered
Basically kind of how the |
…ple for metadata used in semver # Conflicts: # .bumpversion.cfg
a6a7f91
to
35a94f5
Compare
Question is, is this implementation kind of acceptable or possibly causing some side-effects? |
Yes, that is possible with this tool.
You mean setting it back to |
@martinm82
But, unless I'm doing it wrong, I had to add this unused
It is what this pull request is (indirectly) going to fix? |
@dalbani yes this is the way to do that. It is basically the same as in all other implementations (eg. https://github.com/peritus/bumpversion). BTW, for what you want to achieve you don't need the changes from this PR. |
@martinm82 |
[edited comment] Sorry, spoke way too soon! The copy/pasted parse regex was not matching my -dev release name (and my previous iterations had the wrong optional value specified.) I have it working, carry on, sorry for the noise! |
I have hacked this a bit together and would like to get some guidance from you guys how to implement this better.