Skip to content

Latest commit

 

History

History
22 lines (13 loc) · 279 Bytes

File metadata and controls

22 lines (13 loc) · 279 Bytes

Replace String in a File

Use sed:

sed -i '' "s/old string/new string/g" myfile.txt

On Linux use:

sed -i 's/old string/new string/g' myfile.txt

NOTE: Replacements are case sensitive.


Refs