Unix alike system have ed for editing text file which is i feel strange at first. I learned some time ago to create small text file out of curiosity.
Lets try by creating a text file containing 3 lines.
- type ed on terminal
- type a then enter (a is append command in ed)
- type your text file content.
- To end input mode type . then enter on a line.
- Type w filename.txt then enter to save to a file.
- Type q to quit from ed.
Here we will show in a terminal.