When using perl $. variables, you may need to reset $. for each new file.
for example to add #!/usr/bin/perl to each .pl in the current dir do
perl -i -lpe 'print "#!/usr/bin/perl\n" if $. ==1 ; close ARGV if eof' *.pl
Tuesday, March 07, 2006
Subscribe to:
Post Comments (Atom)
No comments:
Post a Comment