[SunHELP] insert one line at beginning of text file; efficien tly
Dale Ghent
daleg at elemental.org
Wed Sep 3 15:48:24 CDT 2003
On Wednesday, September 3, 2003, at 03:39 PM, Markham, Richard wrote:
> Dale if you dont mind if I wanted to pass paramers ($1 $2 .....) to
> theis
> perl
> command how can I get it to go through without PERL trying to process
> the
> variable. Appears the shell never gets to replace the variable value.
Use this perl script instead. Cut and past it into a file, make it
executable, and run it like so: ./foo inputfile argument > outputfile
#!/usr/bin/perl
print "$ARGV[1]\n";
open FILE, $ARGV[0];
while(<FILE>){print;}
/ek
http://elektronkind.org/
Psytrance: it's post-grad school for ravers.
More information about the SunHELP
mailing list