sed tips

sed -i ‘s/fengo/dressholic/g’ * 

sed -i ‘s/Fengo/Dressholic/g’ * 

search folders for file type recurisvely and replace text in file

find . -type f -exec sed -i.bak “s/fengo/dressholic/g” {} \; 

find . -type f -exec sed -i.bak “s/Fengo/Dressholic/g” {} \; 

delete files in folders with extension

find . -name “*.bak*” -type f -delete

Leave a Reply