Shell/Bash: linux replace string in all files Example

By

Shell/Bash Example: This is the "linux replace string in all files" Example. compiled from many sources on the internet by SimpleTutorials.org

linux replace string in all files

sed -i 's/old-text/new-text/g' input.txt

How to replace a string in multiple files in linux command line

cd /path/to/your/folder
sed -i 's/foo/bar/g' *



* Summary: This "linux replace string in all files" Shell/Bash Example is compiled from the internet. If you have any questions, please leave a comment. Thank you!

Others