Search This Blog

Wednesday, May 22, 2013

Replace a word in file Linux Shell

sed -i 's/<word to replace>/<new word>/g'<filenametobereplacedin>

Eg:

sed -i 's/shashwat/shriparv/g'shashwat.txt

No comments:

Post a Comment

Thank you for Commenting Will reply soon ......

Featured Posts

hop – Install Linux Alongside Windows Without a USB Drive Open-source · MIT License Windows 10 / 11

OPEN SOURCE MIT LICENSE WINDOWS 10 / 11 hop – Install Linux Alongside Windows Without a USB Drive What if y...