If it is VIM for Windows, you can do the following:
- enter your message following the presented guidelines
- press Esc to make sure you are out of the insert mode
- then type
:wq
Enter orZZ
.
Note that in VIM there are often several ways to do one thing. Here there is a slight difference though. :wq
Enter always writes the current file before closing it, while ZZ
, :x
Enter, :xi
Enter, :xit
Enter, :exi
Enter and :exit
Enter only write it if the document is modified.
All these synonyms just have different numbers of keypresses.