- Debian Admin - http://www.debianadmin.com -
Howto Replace multiple file text string in Linux
Posted By Admin On 13th August 2007 @ 13:42 In General | 3 Comments
If you're new here, you may want to subscribe to my RSS feed. Thanks for visiting!
grep -R –files-with-matches ‘OLDSTRING’ . | sort | uniq | xargs perl -pi~ -e ’s/OLDSTRING/NEWSTRING/’
Where OLDSTRING is the string you want to find and replace with NEWSTRING.
Tags: Replace multiple file text string in Linux, search and replace text in linuxYou may also be interested in...
Article printed from Debian Admin: http://www.debianadmin.com
URL to article: http://www.debianadmin.com/howto-replace-multiple-file-text-string-in-linux.html
Click here to print.