[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: C-x C-q more useful as toggle-read-only
From: |
Francesco Potorti` |
Subject: |
Re: C-x C-q more useful as toggle-read-only |
Date: |
30 Oct 2000 16:24:59 +0100 |
spiegel@gnu.org (Andre Spiegel) writes:
So maybe it would be natural to have that C-x C-q binding for files
with locking only, and even in that case it could be made into a user
option, whereas C-x v v would be the general VC command for doing the
right thing.
Note though, that this requires a rather drastic change in the VC
documentation, where C-x C-q is consistently documented as the main VC
command.
That probably wouldn't be too difficult. The problem is that it has
been that way for a long time now, and people have learned it that way.
On the positive side, the new VC does handle the special case that
someone complained about: if a file is "locked" (or "modified") but
the buffer is read-only, then C-x C-q will simply make the buffer (and
if needed, also the file) writable, because that is the most sensible
thing to do in that situation.
What about something like what I did for me, that is, ask the user
whether really checking out or just toggling the read-only flag? Like
this:
;;; Addition to 19.30
;;; Ask before using version control: maybe toggle-read-only is enough
(defadvice vc-toggle-read-only (around vc-ask activate)
(if (and (vc-backend buffer-file-name)
(y-or-n-p "Toggle version control status? "))
ad-do-it
(toggle-read-only)))
- Re: C-x C-q more useful as toggle-read-only, (continued)
- Re: C-x C-q more useful as toggle-read-only, Klaus Berndl, 2000/10/24
- Re: C-x C-q more useful as toggle-read-only, Eli Zaretskii, 2000/10/24
- Re: C-x C-q more useful as toggle-read-only, Michael John Downes, 2000/10/24
- Re: C-x C-q more useful as toggle-read-only, Klaus Berndl, 2000/10/25
- Re: C-x C-q more useful as toggle-read-only, Eli Zaretskii, 2000/10/25
- Re: C-x C-q more useful as toggle-read-only, Francesco Potorti`, 2000/10/25
- Re: C-x C-q more useful as toggle-read-only, Klaus Berndl, 2000/10/25
- Re: C-x C-q more useful as toggle-read-only, Andre Spiegel, 2000/10/26
- Re: C-x C-q more useful as toggle-read-only, Michael J Downes, 2000/10/26
- Re: C-x C-q more useful as toggle-read-only, Eli Zaretskii, 2000/10/26
- Re: C-x C-q more useful as toggle-read-only,
Francesco Potorti` <=
- Re: C-x C-q more useful as toggle-read-only, Greg A. Woods, 2000/10/27
- Re: C-x C-q more useful as toggle-read-only, Miles Bader, 2000/10/27
- Re: C-x C-q more useful as toggle-read-only, Eli Zaretskii, 2000/10/27
- Re: C-x C-q more useful as toggle-read-only, Andreas Schwab, 2000/10/27