[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: How to inhibit version control for a single command.

From: Kim F. Storm
Subject: Re: How to inhibit version control for a single command.
Date: 25 Aug 2003 11:55:28 +0200
User-agent: Gnus/5.09 (Gnus v5.9.0) Emacs/21.3.50

"Stefan Monnier" <monnier+gnu/address@hidden> writes:

> > In ido, I used to be able to let bind vc-master-templates to nil to
> > temporarily inhibit version control for a single command (e.g. avoid
> > the CVS up-to-date check when the CVS repository is accessed over a
> > slow WAN link).  I have used a similar hack in connection with M-x
> > grep where I don't want to have the up-to-date check just to look at
> > the matching lines.
> Since Emacs-21, the slow access should never happen upon find-file
> (only upon vc-next-action or somesuch).  Otherwise, it's a bug and
> you should report it.
> > Now the vc-master-templates variable is obsolete and it's suggested to
> > use vc-BACKEND-master-templates instead, but then I have to let bind
> > several variables to accomplish the same effect.
> The suggestion is meant for when you set the var to a non-nil value.
> In your case the "replacement" is vc-handled-backends, but as mentioned
> above if you need to bind it to nil, it might be due to a bug.

At my previous employer, we were using a hacked up version of CVS
which enforced _mandatory_ file locking, and vc (from 20.x) was
modified to support thi.

This meant that whenever we opened -- or visited -- a file in emacs,
it would have to go to the CVS server (over a slow WAN link) to check
whether someone else had locked the file (using "cvs editors").  This
obviously caused many unnecessary checks when just browsing through a
list of grep matches or compiler warnings (in other people's modules).

So I made the hack to ido and other packages to disable vc checking
when I only wanted to view a file.

I'm a bit puzzled that vc can now always do without any checking
against the archive when opening a file, as it may be quite useful to
know whether other people are editing the same file as you.

But I agree that the new functionality (only check on next-action) is
sufficient, and the advantages (higher performance) out-weights the

Thanks to Andre for the advice on using vc-handled-backends; I guess I
don't need it anyway, but it's nice to know.

Kim F. Storm <address@hidden> http://www.cua.dk

reply via email to

[Prev in Thread] Current Thread [Next in Thread]