bumpversion fails when version is wrapped in quotes
See original GitHub issueI have several applications that use bumpversion. The latest release has caused a breaking change. I have files like the following
.bumpversion.cfg
bumpversion]
current_version = 1.90.0
parse = (?P<major>\d+)\.(?P<minor>\d+)\.(?P<patch>\d+)
commit = True
tag = True
message = "Bump version: {current_version} → {new_version} [ci skip]"
serialize =
{major}.{minor}.{patch}
[bumpversion:file:./version.sh]
search = CONF_VERSION={current_version}
replace = {new_version}
version.sh
CONF_VERSION='1.90.0'
when my build runs bumpversion minor
it errors because it cannot find the version in the file version.sh
I figured out the it is because the value in wrapped in single quotes. This worked fine in version 1.0.0 but is now broken in 1.0.1
Issue Analytics
- State:
- Created 3 years ago
- Reactions:1
- Comments:13 (5 by maintainers)
Top Results From Across the Web
Bump2version fails with the new black code formatter #145
It formats all single quotes ' as double quotes ", which in turn causes ... [bumpversion:file:protoattend/__init__.py] search = __version__ ...
Read more >Bump - Commitizen
Bump version. About. The version is bumped automatically based on the commits. ... use it in existing projects, wrap around simple quotes --bump-message ......
Read more >Versioning using bumpversion - William Hayes, PhD
Bumpversion (use bump2version instead — it installs a command called ... 21, 23 — else you'll get an error message trying to run...
Read more >Add permission API backend for macOS and iOS (Ic2a43e1a)
macOS: Ensure proper quoting when calling otool in objc_namespace script (Merged) ... Continuous Integration: Failed Failed to build sources.
Read more >How to Publish an Open-Source Python Package to PyPI
Compared to the version currently published on PyPI, this version lacks some error handling and extra options.
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
There was some breaking change. But it is still usable, just change your .bumpversion.cfg to:
In my opinion the previous behavior sounds strange… maybe it did not find the search-string and then did fall back to the default search/replace?
I just confirmed, bumpversion is no longer usable due to this error. I recommend that users use
bump2version==1.0.0