You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I would like to bump the version in a package-lock.json. Currently I cannot figure out how to do this safely. A typical package-lock.json has the format:
The issue is that this will update ANY package that happens to have the version 1.2.3 or even 1.2.39, because they all match the word "version". In this example node_modules/another/project would also be updated
I have tried searching for a solution for this but cannot find anything in the docs for version_files. Can you please suggest how this can be done?
Possible Solution
Alternatively, to get round this, you could specify a slice (possibly using python's slice syntax) which would modify only a range of occurrences out of all the possible matches. For example
Yep, I think it's something we've not yet supported. Currently, we split files by line and try to match the regular expression here. My idea is to support matching the multi-line regular expression. Feel free to send us a PR if you're interested in it :)
Description
I would like to bump the version in a package-lock.json. Currently I cannot figure out how to do this safely. A typical package-lock.json has the format:
As per the documentation, I would like to increase the "version" inside the package.lock using the following .cz.yaml config:
The issue is that this will update ANY package that happens to have the version
1.2.3
or even1.2.39
, because they all match the word "version". In this examplenode_modules/another/project
would also be updatedI have tried searching for a solution for this but cannot find anything in the docs for
version_files
. Can you please suggest how this can be done?Possible Solution
Alternatively, to get round this, you could specify a slice (possibly using python's slice syntax) which would modify only a range of occurrences out of all the possible matches. For example
This would would update the first 2 occurrences but would stop there.
If there is another solution that already exists please let me know
Additional context
No response
Additional context
No response
The text was updated successfully, but these errors were encountered: