-
-
Notifications
You must be signed in to change notification settings - Fork 297
-
Hello,
from the documentation, it seems that paths in version_files
can be either
- relative to execution path
- absolute path
- glob patterns
I might be missing something, but IMHO a sensible option would be to also specify files relatively to the commitizen configuration file's path. For example:
# /home/myself/project/cz.toml
[tool.commitizen]
version_files = [
"src/__version__.py", # relative to execution path: won't update if we call `cz bump` from the project `src` dir
"$CZCONFIG/src/__version__.py", # relative to where the cz config file is, will always update the file
]
In this case, $CZCONFIG
would make that path relative to /home/myself/project/
.
Is something like this currently possible?
EDIT: clearly I'm avoiding absolute paths so that configurations can be shared among multiple workstation/people/locations/etc.
Beta Was this translation helpful? Give feedback.
All reactions
I think it's (or should be) based on config file 🤔 If not, it sounds like a bug to me. but I'll need to test it out
Replies: 2 comments
-
I think it's (or should be) based on config file 🤔 If not, it sounds like a bug to me. but I'll need to test it out
Beta Was this translation helpful? Give feedback.
All reactions
-
This issue is not tracking in #1371
Beta Was this translation helpful? Give feedback.