mirror of
git://git.sv.gnu.org/emacs.git
synced 2026-04-27 16:51:06 -07:00
(vc-sccs-diff-switches): New customization option.
(vc-sccs-diff): Use it via vc-diff-switches-list. (vc-sccs-workfile-unchanged-p): Return correct status.
This commit is contained in:
parent
10489ed706
commit
a1e9f194d2
1 changed files with 23 additions and 12 deletions
|
|
@ -5,7 +5,7 @@
|
|||
;; Author: FSF (see vc.el for full credits)
|
||||
;; Maintainer: Andre Spiegel <spiegel@gnu.org>
|
||||
|
||||
;; $Id: vc-sccs.el,v 1.6 2001/01/08 16:26:44 spiegel Exp $
|
||||
;; $Id: vc-sccs.el,v 1.7 2001/01/09 14:55:30 fx Exp $
|
||||
|
||||
;; This file is part of GNU Emacs.
|
||||
|
||||
|
|
@ -28,6 +28,9 @@
|
|||
|
||||
;;; Code:
|
||||
|
||||
(eval-when-compile
|
||||
(require 'vc))
|
||||
|
||||
;;;
|
||||
;;; Customization options
|
||||
;;;
|
||||
|
|
@ -44,6 +47,17 @@ A string or list of strings passed to the checkin program by
|
|||
:version "21.1"
|
||||
:group 'vc)
|
||||
|
||||
(defcustom vc-sccs-diff-switches nil
|
||||
"*A string or list of strings specifying extra switches for `vcdiff',
|
||||
the diff utility used for SCCS under VC."
|
||||
:type '(choice (const :tag "None" nil)
|
||||
(string :tag "Argument String")
|
||||
(repeat :tag "Argument List"
|
||||
:value ("")
|
||||
string))
|
||||
:version "21.1"
|
||||
:group 'vc)
|
||||
|
||||
(defcustom vc-sccs-header (or (cdr (assoc 'SCCS vc-header-alist)) '("%W%"))
|
||||
"*Header keywords to be inserted by `vc-insert-headers'."
|
||||
:type '(repeat string)
|
||||
|
|
@ -128,9 +142,9 @@ For a description of possible values, see `vc-check-master-templates'."
|
|||
|
||||
(defun vc-sccs-workfile-unchanged-p (file)
|
||||
"SCCS-specific implementation of vc-workfile-unchanged-p."
|
||||
(apply 'vc-do-command nil 1 "vcdiff" (vc-name file)
|
||||
(list "--brief" "-q"
|
||||
(concat "-r" (vc-workfile-version file)))))
|
||||
(zerop (apply 'vc-do-command nil 1 "vcdiff" (vc-name file)
|
||||
(list "--brief" "-q"
|
||||
(concat "-r" (vc-workfile-version file))))))
|
||||
|
||||
|
||||
;;;
|
||||
|
|
@ -291,14 +305,11 @@ EDITABLE non-nil means previous version should be locked."
|
|||
"Get a difference report using SCCS between two versions of FILE."
|
||||
(setq oldvers (vc-sccs-lookup-triple file oldvers))
|
||||
(setq newvers (vc-sccs-lookup-triple file newvers))
|
||||
(let* ((diff-switches-list (if (listp diff-switches)
|
||||
diff-switches
|
||||
(list diff-switches)))
|
||||
(options (append (list "-q"
|
||||
(and oldvers (concat "-r" oldvers))
|
||||
(and newvers (concat "-r" newvers)))
|
||||
diff-switches-list)))
|
||||
(apply 'vc-do-command t 1 "vcdiff" (vc-name file) options)))
|
||||
(apply 'vc-do-command t 1 "vcdiff" (vc-name file)
|
||||
(append (list "-q"
|
||||
(and oldvers (concat "-r" oldvers))
|
||||
(and newvers (concat "-r" newvers)))
|
||||
(vc-diff-switches-list sccs))))
|
||||
|
||||
|
||||
;;;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue