Editing Comment Buffers

There are three operations in VC that typically pop up a buffer to accept comment or notification text; check in, lock stealing, and (under circumstances to be explained later in the chapter) file registration. In each case, the operation is on hold until you type C-c C-c to commit the comment buffer. You can enter a comment right away and finish the operation, or you can go off and do something else. VC is not modeful (remember the discussion of modeful versus modeless interfaces in Chapter 14); it waits patiently to commit until you are ready. If you delete the pop-up buffer, the operation is quietly scrubbed.

The comment buffer is a plain-text buffer. However, each time you commit a comment buffer, the contents are saved to a new slot in a ring of comment buffers. You can cycle backwards in the ring with ESC p and forward with ESC n, or you can search for text backwards in the ring with ESC r and forward with ESC s. By design, these are the same keys you can use to navigate an Emacs minibuffer command history. By far the most commonly used of these commands is ESC p. Being able to recall and edit the last change comment is often useful.

Get Learning GNU Emacs, Second Edition now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.