how to replace word in file in linux code example
Example 1: linux replace string in all files
sed -i 's/old-text/new-text/g' input.txt
Example 2: sed replace in file
sed -i 's/foo/bar/g' hello.txt
Example 3: replace word in file linux command
sed -i 's_oldword_replaceword_gI' document_name.txt