Personally prefer :xprobably because it’s a little more ergonomic, as Z is all the way in the corner (QWERTY), and is the same key twice, while : and x are in two different spots, and can therefore be hit faster.
I know, it’s like millisecond differences, but, hey, I’m a vim user.
:x will save and exit. The difference between :x and :wq is that the latter will always write to the buffer, while the former will only do so if theres a change.
Don’t save:
:q!Save::xAdditionally for save and exit:
:wq(read as write and quit) orZZ(without colon).Dude’s in bed.
ZZis clearly the superior choice for the sleepy vi user.Personally prefer
:xprobably because it’s a little more ergonomic, as Z is all the way in the corner (QWERTY), and is the same key twice, while:andxare in two different spots, and can therefore be hit faster.I know, it’s like millisecond differences, but, hey, I’m a vim user.
:xwill save and exit. The difference between:xand:wqis that the latter will always write to the buffer, while the former will only do so if theres a change.Sup. And
ZZis like:x, write only if change was made.I like
:cqfor if I want to cancel my git commit message (or similar)