NLeSC / python-template

Netherlands eScience Center Python Template
https://research-software-directory.org/software/nlesc-python-template
Apache License 2.0
163 stars 73 forks source link

bump-my-version: use explicit search patterns #367

Open egpbos opened 6 months ago

egpbos commented 6 months ago

As mentioned here by @stefsmeets, it might be smarter to use explicit search patterns for finding and replacing the versions using bump-my-version. The default behavior is to just do a search-and-replace on the raw version string anywhere in the file. For some files this may not be an issue, for instance when there's not expected to be any other version strings in the file. For pyproject.toml, however, it can lead to versions of dependencies to be changed as well if they happen to match your package's version.