Last active
December 14, 2015 15:08
-
-
Save seamountain/5105281 to your computer and use it in GitHub Desktop.
Script of sed all files on Mac OSX.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
files_path=path/to/directory | |
cd $files_path && find . -name "*.feature" | xargs sed -i '' "s/[0-9]*_//g" |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
The script can replace, but saved file name is wrong. I want to just replace the files.gsed is not work too...
We cannot use "+" as regex.
http://www.tutorialspoint.com/unix/unix-regular-expressions.htm