in reply to Writing to files
All the above good advice applies, but one liners are cool:
perl -i -p -e "BEGIN{print 'A new line!\n';}" your files here
In Section
Seekers of Perl Wisdom