can anybody please give some quick reference in how to insert characters or line of characters to a file... and how to exit the insert mode in the regular expression.

ed try.txt
1,$p -->prints everything
how do i get in to the insert mode ? " i " ???
then... how do i insert characters to this file?
then... how do i exit insert mode


Hey There,

Check this page for all the options:

As for the insert mode, it's the same as vi. i will put you in insert mode at the position you are, and "a" will put you in insert mode right after your position in the file. You can exit insert by doing a ctl-c or any interrupt signal.

Best wishes,