perl -i # edit in place .bak # rename original file by appending .bak to filename; print to new file with original name -p # use a while loop to read each file; print each line (is stored in $_) which you have read (and modified) e # excecute code from command line ' # start of code to be executed (for the default while loop) $_ # default variable, each line of file .= # append the following to yourself ($_) and assign it to you "\n" # string to be appended ' # end of code