Open jgroom33 opened 5 years ago
I was having the same problem. Apparently, if bump2version doesn't find the search
pattern, it falls back to the default {current_version}
.
In my case, I had a typo in the pattern, and that was producing the same result as yours. After fixing it, it worked as expected.
In this scenario, there is no misspelling. It is desirable that there is no fallback.
Ideally, there should be a way to handle changes.md in a better manner while migrating from dev version to patch/minor/major version and back.
Specifically, the goal is to have 'version future' only exist in the dev version. This would be replaced with the minor/major/patch during bump. When bump to dev, 'version future' is reapplied.
Yes, I agree it shouldn't fall back to the default pattern. If it doesn't find the specified search
pattern, it should simply skip the file.
I agree that the fallback should not occur. Issue #76 was a similar confusion caused by it.
At the very least, the fallback should generate some very explicit warning.
Current behavior:
config:
Assume this CHANGES.md:
bump2version patch
Result:Expected result: