3 ms·
Bad advice. Just :q not :q! Let it give you the warning and then hit :q! if you're really sure. Also, it's probably better to tell new vi users to write and e
by gweinberg 3y ago
Bad advice.
Just :q
not :q!
Let it give you the warning and then hit :q! if you're really sure.
Also, it's probably better to tell new vi users to write and exit with
:w
it works just as well and is more consistent.
- red_trumpet 3y ago:w only writes, doesn't exit. :wq writes and exits, or :x
- silisili 3y agoI use :wq always when saving and exiting so I can see and remember exactly what's happening, despite shortcuts existing. And :q when just exiting as you mentioned for exactly this reason. Tell me I'm quitting without saving so I can decide what to do next.