cmdline editor is now complete

- implemented inserting and deleting in the middle of the line
- fixed a bug in END routine