buy tb500

Find and replace in Linux file

if in single file

sed -i ‘s/ugly/beautiful/g’ /home/bruno/old-friends/sue.txt

if in multiple files

$ find /home/bruno/old-friends -type f -exec sed -i ‘s/ugly/beautiful/g’ {} \;

 

Thanks.

 

Leave a Reply


Warning: Undefined variable $user_ID in /home/alzweac/public_html/knowledge/wp-content/themes/diet1/comments.php on line 74