P is for Practical | |
PerlMonks |
Re: Newbie: uses/limits of perl in editing filesby Sixtease (Friar) |
on Nov 23, 2007 at 14:08 UTC ( [id://652567]=note: print w/replies, xml ) | Need Help?? |
You can do this with pretty much any scripting / programming language (if it has input/output capabilities and is turing-complete). And Perl may be the most comfortable one for this. The code to do something like you said could look like perl -pe '/^REMARK/ and print "the line you want to add\n"' < input_file > output_file
In Section
Seekers of Perl Wisdom
|
|