(no title)
smush | 6 years ago
If you have flailed around and messed with a file because when you type, it ignores your input until you use the 'i' character, suddenly you need to stop, close and reopen the file (because you don't know to hold the u key to undo). So, you do what works on DOS or nano, and hit Ctrl + C.
Someone coded it such that if you hit Ctrl + C to exit, instead of exiting out of VIM immediately, the editor writes a message that says "to exit vim, you must type :quit".
So you type that, and VIM responds with 'you have unsaved changes, please add ! to overwrite', so you type ! and it does nothing. After several seconds of confusion, you google how to get out of vim and the internet reveals the magic keystrokes ":q!" to finally get out of this dad blame file and get back to what you were doing.
All of that (probably, in my cynical mind) to avoid following the principle of least surprise and have Ctrl + C = close, discard changes.
No comments yet.