4 ms·
May be. However, my memory is of 2 factors that made line editors like ed necessary. 1. The keyboard mechanics and having paper as the output medium made typi
by RegW 5y ago
May be. However, my memory is of 2 factors that made line editors like ed necessary.
1. The keyboard mechanics and having paper as the output medium made typing very slow. That's probably why all the commands were short (ls, mv, rm, etc). Coding was not the stream of consciousness you might experience today. You would have to hold a load of stuff in your head (and ignore interruptions) as you slowly typed it out.
2. The paper only ever advances upwards. If you make a mistake there is no up arrow. Your easiest option may be to use the delete command and type the whole line again. Hopefully someone will give you one of those paper cheat sheet summarizing all the editor commands soon. I wonder how many potential computer geniuses dropped out of CS at this point.
Imagine you are at the command line and you take a few minutes to quickly type:
$ cp inupt_KJuusiwbHSgh.txt output_HswbXVfgawYuq.txt
cp: cannot stat 'inupt_KJuusiwbHSgh.txt': No such file or directory
Rats! You didn't notice that you mistyped "input". What now? You can't do copy and paste from paper! Well you could use the line editor:
$ !!:s/up/pu
cp input_KJuusiwbHSgh.txt output_HswbXVfgawYuq.txt
Job done.