List of ed commands a insert After the current line (until a . on its own) c change lines and input new text (until . on its own) d delete the line or lines e enter a new file/edit that file f filename - print it or change it. i insert before the first of addressed lines(until . on a line) k Keep note of this line (as in ka, kb, kc, ), mark this line l list with tabs shown as >, BS as < CR as $ m move lines to line after this line (including m0 - move to start) p print line ( can also be put after a substitution to see the result) q quit (a ? means that you haven't saved your file...do it again) r read a file after the the addressed lines s substitute -- s/old/new/ s?old?new? etc. & is special in new! t transpose to other line - actually it puts in a copy! u undo the last s w write current file out (or addressed part of file), save it = print the number of the lines ! obey this unix(shell) command - !ls or !pwd Try 'help ed3' to see more syntax and special symbols.