1 Jun 2002 16:50
How am I supposed to make a buffer read-only?
Alan Mackenzie <none <at> example.invalid>
2002-06-01 14:50:13 GMT
2002-06-01 14:50:13 GMT
Gnu Emacs 21.1 I just tried C-x C-q, and got the error message back: "/my/path/foo.el is up-to-date" in the minibuffer. [foo.el is a CVSed file.] Bug: The buffer remained writable. [Possibly relevant: the cvs server is at the other end of a modem connection which wasn't up at the time, thankfully.] A quick C-h k revealed that the normal, simple, sane, sensible binding has been overridden by vc-toggle-read-only, a mis-named function if ever there were one. It seems to regard checking a file in as a perfectly sensible "method" of making it's buffer read-only. Ye Gods! Is there really some semantic identity between changing the read-only status of a buffer, and checking it's file about? Damned if I can see it. Particularly when the version control system is CVS. I thought it was only commercial version control systems that were lazy/fascistic enough to (ab)use files' read-only status to mark their check-outedness. Checking a file in/out is one thing. Changing the read-only status of a buffer is something completely different. Surely? Somebody please tell me I'm having a bad dream, and I'll wake up soon. Do I really have to type M-x toggle-read-only for evermore, so as to avoid the risk of accidentally checking a file in/out? Suggestion: C-x C-q should be reserved for toggle-read-only, and something else (C-x v v, presumably) for checking files in/out.(Continue reading)
RSS Feed