I am using vi editor
to write scripts, however I have made a mistake deleting some lines of code without saving. Now I would like to undo the changes. The way I found to do that was to use the u keystroke
to undo the changes and it worked fine.
Now I was thinking to just quit the vi editor in the current state without saving the changes so I try
- Press
Esc
key - Press
:q
to quit
It gives me an error
No write since the last change vi error while quitting
How do I get over with this error
Thanks for help.