Languages
[Edit]
EN

Linux - how to exit vim editor?

14 points
Created by:
JustMike
28060

Fast manual - quit without saving

Below steps show how to quit vim editor without saving any changes:

  • Press:┬áEsc
  • Press:┬á:┬á(colon)
  • Type:┬áq!
  • Press:┬áEnter

In details manual - step by step

To quit the vi / vim editor without saving any changes you've made:

If you are currently in insert or append mode

  • Press:┬áEsc
  • Press:┬á:┬á(colon)

The cursor should reappear at the lower left corner of the screen beside a colon prompt.

  • Type:┬áq!
  • Press:┬áEnter

Other option - save and quit

If we want to save the changes and quit change only 1 step, instead of q! we type wq

  • Press:┬áEsc
  • Press:┬á:┬á(colon)
  • Type:┬áwq
  • Press:┬áEnter

Other option - save and still stay in vim

If we want just to save the changes and still stay in vim

Enter the following:

  • Press:┬áEsc
  • Press:┬á:┬á(colon)
  • Type:┬áq
  • Press:┬áEnter

 

Native Advertising
­čÜÇ
Get your tech brand or product in front of software developers.
For more information Contact us
Dirask - we help you to
solve coding problems.
Ask question.

ÔŁĄ´ŞĆ­čĺ╗ ­čÖé

Join