Well this is another issue faced by noobs. According to a recent report (Stack Overflow: Helping One Million Developers Exit Vim) exiting VIM is one of the most searched article on Stack Overflow. This article is intended to help noobs exit in a Linux environment.
Exiting the CLI
To force quit or “kill” a running command, you can use “Ctrl + C”. most of the applications running from the terminal will be forced to quit.
Exiting Nano Editor
If you are using the nano editor, simply press “Ctrl + X” to exit. This will prompt you whether you want to save before quitting or not.
Exiting VIM
- Press “Esc” to initiate exit sequence
- Then type a colon “:” Remember after pressing Esc and “;“, you may not see this action taking place, but simply continue with the next step
- Continue typing “q!” to force quit without saving. If you want to save the changes instead of “q!“, type “wq” (This means write then quit).