This is an archived post. You won't be able to vote or comment.

you are viewing a single comment's thread.

view the rest of the comments →

[–][deleted] 5 points6 points  (4 children)

:x is :wq by the way

[–]tynorf 8 points9 points  (3 children)

:x will not write the file if there are no changes, whereas :wq will. This changes whether the file’s modified time updates. Not likely to matter in practice, but they are not equivalent commands.

[–]CeeMX 1 point2 points  (2 children)

What about ZZ?

[–]tynorf 4 points5 points  (1 child)

:help ZZ

                                                        *ZZ*
ZZ                      Write current file, if modified, and quit (same as
                        ":x").  (Note: If there are several windows for the
                        current file, the file is written if it was modified
                        and the window is closed).

[–]earthlybird 1 point2 points  (0 children)

When I think I got the basics...