From f354c160dad0cca49d7d54d41bcb1ba8f5eadc3b Mon Sep 17 00:00:00 2001 From: =?utf8?q?Andr=C3=A9=20Spiegel?= Date: Wed, 23 Apr 2003 13:14:16 +0000 Subject: [PATCH] (vc-cvs-stay-local): Keep the old default. Simplify doc string. --- lisp/vc-cvs.el | 27 +++++++++++++-------------- 1 file changed, 13 insertions(+), 14 deletions(-) diff --git a/lisp/vc-cvs.el b/lisp/vc-cvs.el index ab69de81d77..474d4ca7330 100644 --- a/lisp/vc-cvs.el +++ b/lisp/vc-cvs.el @@ -5,7 +5,7 @@ ;; Author: FSF (see vc.el for full credits) ;; Maintainer: Andre Spiegel -;; $Id: vc-cvs.el,v 1.54 2003/04/19 22:40:18 monnier Exp $ +;; $Id: vc-cvs.el,v 1.55 2003/04/23 12:49:25 spiegel Exp $ ;; This file is part of GNU Emacs. @@ -81,18 +81,17 @@ This is only meaningful if you don't use the implicit checkout model :version "21.1" :group 'vc) -(defcustom vc-cvs-stay-local '(except "^\\(localhost\\)$") +(defcustom vc-cvs-stay-local t "*Non-nil means use local operations when possible for remote repositories. This avoids slow queries over the network and instead uses heuristics and past information to determine the current status of a file. + The value can also be a regular expression or list of regular expressions to match against the host name of a repository; then VC -only stays local for hosts that match it. -This is useful in a setup, where most CVS servers should be contacted -directly, and only a few CVS servers cannot be reached easily. -For the opposite scenario, when only a few CVS servers are to be -queried directly, a list of regular expressions can be specified, -whose first element is the symbol `except'." +only stays local for hosts that match it. Alternatively, the value +can be a list of regular expressions where the first element is the +symbol `except'; then VC always stays local except for hosts matched +by these regular expressions." :type '(choice (const :tag "Always stay local" t) (const :tag "Don't stay local" nil) (list :format "\nExamine hostname and %v" :tag "Examine hostname ..." @@ -736,9 +735,9 @@ See `vc-cvs-stay-local'." (vc-file-setprop dirname 'vc-cvs-stay-local-p (when (file-readable-p rootname) - (with-temp-buffer - (vc-insert-file rootname) - (goto-char (point-min)) + (with-temp-buffer + (vc-insert-file rootname) + (goto-char (point-min)) (looking-at "\\([^\n]*\\)") (let* ((cvs-root-members (vc-cvs-parse-root (match-string 1))) @@ -763,13 +762,13 @@ See `vc-cvs-stay-local'." (cdr vc-cvs-stay-local)) "\\|")))) (if (not rx) - 'yes + 'yes (if (not (string-match rx hostname)) (setq stay-local (not stay-local))) (if stay-local - 'yes + 'yes 'no)))))))))))) - (if (eq prop 'yes) t nil)))) + (if (eq prop 'yes) t nil)))) (defun vc-cvs-parse-root ( root ) "Split CVS ROOT specification string into a list of fields. -- 2.39.2