In Perl, how do I change, delete, or insert a line in a file, or append to the beginning of a file?
(This is the official perlfaq answer, minus any subsequent edits) The basic idea of inserting, changing, or deleting a line from a text file involves reading and printing the file to the point you want to make the change, making the change, then reading and printing the rest of the file. Perl doesn’t provide random … Read more