if you just need to make that one substitution in test.txt, with no other conditions or considerations. Check the -i switch documented in the perlrun POD to see how to make a safe backup of the original file in the process.perl -pi -e 's!/prj/sw/tool!/prj/vlsi/toolsmodule!;' test.txt
In reply to Re: change a line or string in file
by hsinclai
in thread change a line or string in file
by sachin_chat
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |