[Israel.pm] -i and more
Yossi.Itzkovich at ecitele.com
Yossi.Itzkovich at ecitele.com
Mon Apr 19 03:56:45 PDT 2004
Hi,
I need to write a scipt that gets: inFileName outFileName oldStr newStr
The script should be a simple one that replaces all occurances of oldStr
with newStr from inFileName, and save it in outFileName
I can do it in the long way or in the shorter (and much simpler ) way.
My questions:
1. the -i flag saves the output file with the original name
+suffix/prefix. In this case I need to use a name given by the user.
2. The oldStr/newStr may contain wierd characters such as */\@ etc. I do
I prevernt meta characters to affect my perl code ?
Thanks
Yossi
More information about the Perl
mailing list