-
Notifications
You must be signed in to change notification settings - Fork 585
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Replacements in ReplaceInFiles should accept regex patterns #622
Comments
This would be a breaking change, right? I mark this as up-for-grabs if you are interested please send a PR. |
Yeah. That might be a breaking change. Perhaps an additional argument with a default value could be added that defaulted to the current behavior but when provided would use regex to find matches? Then again, perhaps a separate ReplaceInFilesRegex would be cleaner. |
…sprojects#622 The current implementation requires that the caller specify the encoding for the files that they are processing. Future enhancements may include auto-detection of the file encoding to make usage a little cleaner.
You can just close issues when things are fixed. Thanks |
Currently, it appears the patterns used in ReplaceInFiles must match the string you want to replace exactly. However, it would be very helpful if instead of an exact match the regular expressions could be used in the pattern matching. This would enable, for instance, replacing version strings in arbitrary files with an expression akin to:
The text was updated successfully, but these errors were encountered: