![]() |
|
Problems? Is your data what you think it is? | |
PerlMonks |
Re: perl's command line snippet which I read from a perl article ( perl tutrous )by Hue-Bond (Priest) |
on Sep 06, 2006 at 07:23 UTC ( #571387=note: print w/replies, xml ) | Need Help?? |
-i tells Perl that the files read with the diamond operator (<>) are going to be edited in place, and that a backup of the original file will be kept, using the extension specified. So, -i~ will create a copy of the file with a tilde appended to its name. But, where's the <> coming from? It's from -p, which causes the program to be enclosed into a loop that does a while(<>). Whether you committed a mistake or not, depends on what you intended to do ;^). --
In Section
Seekers of Perl Wisdom
|
|