annotate lisp/vc-sccs.el @ 35503:dc575312bb6f

*** empty log message ***
author Andrew Innes <andrewi@gnu.org>
date Wed, 24 Jan 2001 12:31:07 +0000
parents 1b423e7eb1eb
children 9396894025fa
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
31385
b1e1a94dfc0a (vc-sccs-latest-on-branch-p): Always return t; we
Gerd Moellmann <gerd@gnu.org>
parents:
diff changeset
1 ;;; vc-sccs.el --- support for SCCS version-control
b1e1a94dfc0a (vc-sccs-latest-on-branch-p): Always return t; we
Gerd Moellmann <gerd@gnu.org>
parents:
diff changeset
2
b1e1a94dfc0a (vc-sccs-latest-on-branch-p): Always return t; we
Gerd Moellmann <gerd@gnu.org>
parents:
diff changeset
3 ;; Copyright (C) 1992,93,94,95,96,97,98,99,2000 Free Software Foundation, Inc.
b1e1a94dfc0a (vc-sccs-latest-on-branch-p): Always return t; we
Gerd Moellmann <gerd@gnu.org>
parents:
diff changeset
4
b1e1a94dfc0a (vc-sccs-latest-on-branch-p): Always return t; we
Gerd Moellmann <gerd@gnu.org>
parents:
diff changeset
5 ;; Author: FSF (see vc.el for full credits)
b1e1a94dfc0a (vc-sccs-latest-on-branch-p): Always return t; we
Gerd Moellmann <gerd@gnu.org>
parents:
diff changeset
6 ;; Maintainer: Andre Spiegel <spiegel@gnu.org>
b1e1a94dfc0a (vc-sccs-latest-on-branch-p): Always return t; we
Gerd Moellmann <gerd@gnu.org>
parents:
diff changeset
7
35179
1b423e7eb1eb (vc-sccs-header): Fix :type.
Dave Love <fx@gnu.org>
parents: 35134
diff changeset
8 ;; $Id: vc-sccs.el,v 1.6 2001/01/08 16:26:44 spiegel Exp $
31385
b1e1a94dfc0a (vc-sccs-latest-on-branch-p): Always return t; we
Gerd Moellmann <gerd@gnu.org>
parents:
diff changeset
9
b1e1a94dfc0a (vc-sccs-latest-on-branch-p): Always return t; we
Gerd Moellmann <gerd@gnu.org>
parents:
diff changeset
10 ;; This file is part of GNU Emacs.
b1e1a94dfc0a (vc-sccs-latest-on-branch-p): Always return t; we
Gerd Moellmann <gerd@gnu.org>
parents:
diff changeset
11
b1e1a94dfc0a (vc-sccs-latest-on-branch-p): Always return t; we
Gerd Moellmann <gerd@gnu.org>
parents:
diff changeset
12 ;; GNU Emacs is free software; you can redistribute it and/or modify
b1e1a94dfc0a (vc-sccs-latest-on-branch-p): Always return t; we
Gerd Moellmann <gerd@gnu.org>
parents:
diff changeset
13 ;; it under the terms of the GNU General Public License as published by
b1e1a94dfc0a (vc-sccs-latest-on-branch-p): Always return t; we
Gerd Moellmann <gerd@gnu.org>
parents:
diff changeset
14 ;; the Free Software Foundation; either version 2, or (at your option)
b1e1a94dfc0a (vc-sccs-latest-on-branch-p): Always return t; we
Gerd Moellmann <gerd@gnu.org>
parents:
diff changeset
15 ;; any later version.
b1e1a94dfc0a (vc-sccs-latest-on-branch-p): Always return t; we
Gerd Moellmann <gerd@gnu.org>
parents:
diff changeset
16
b1e1a94dfc0a (vc-sccs-latest-on-branch-p): Always return t; we
Gerd Moellmann <gerd@gnu.org>
parents:
diff changeset
17 ;; GNU Emacs is distributed in the hope that it will be useful,
b1e1a94dfc0a (vc-sccs-latest-on-branch-p): Always return t; we
Gerd Moellmann <gerd@gnu.org>
parents:
diff changeset
18 ;; but WITHOUT ANY WARRANTY; without even the implied warranty of
b1e1a94dfc0a (vc-sccs-latest-on-branch-p): Always return t; we
Gerd Moellmann <gerd@gnu.org>
parents:
diff changeset
19 ;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
b1e1a94dfc0a (vc-sccs-latest-on-branch-p): Always return t; we
Gerd Moellmann <gerd@gnu.org>
parents:
diff changeset
20 ;; GNU General Public License for more details.
b1e1a94dfc0a (vc-sccs-latest-on-branch-p): Always return t; we
Gerd Moellmann <gerd@gnu.org>
parents:
diff changeset
21
b1e1a94dfc0a (vc-sccs-latest-on-branch-p): Always return t; we
Gerd Moellmann <gerd@gnu.org>
parents:
diff changeset
22 ;; You should have received a copy of the GNU General Public License
b1e1a94dfc0a (vc-sccs-latest-on-branch-p): Always return t; we
Gerd Moellmann <gerd@gnu.org>
parents:
diff changeset
23 ;; along with GNU Emacs; see the file COPYING. If not, write to the
b1e1a94dfc0a (vc-sccs-latest-on-branch-p): Always return t; we
Gerd Moellmann <gerd@gnu.org>
parents:
diff changeset
24 ;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
b1e1a94dfc0a (vc-sccs-latest-on-branch-p): Always return t; we
Gerd Moellmann <gerd@gnu.org>
parents:
diff changeset
25 ;; Boston, MA 02111-1307, USA.
b1e1a94dfc0a (vc-sccs-latest-on-branch-p): Always return t; we
Gerd Moellmann <gerd@gnu.org>
parents:
diff changeset
26
b1e1a94dfc0a (vc-sccs-latest-on-branch-p): Always return t; we
Gerd Moellmann <gerd@gnu.org>
parents:
diff changeset
27 ;;; Commentary:
b1e1a94dfc0a (vc-sccs-latest-on-branch-p): Always return t; we
Gerd Moellmann <gerd@gnu.org>
parents:
diff changeset
28
b1e1a94dfc0a (vc-sccs-latest-on-branch-p): Always return t; we
Gerd Moellmann <gerd@gnu.org>
parents:
diff changeset
29 ;;; Code:
b1e1a94dfc0a (vc-sccs-latest-on-branch-p): Always return t; we
Gerd Moellmann <gerd@gnu.org>
parents:
diff changeset
30
33560
da206bbad86b Functions reordered.
André Spiegel <spiegel@gnu.org>
parents: 31520
diff changeset
31 ;;;
da206bbad86b Functions reordered.
André Spiegel <spiegel@gnu.org>
parents: 31520
diff changeset
32 ;;; Customization options
da206bbad86b Functions reordered.
André Spiegel <spiegel@gnu.org>
parents: 31520
diff changeset
33 ;;;
da206bbad86b Functions reordered.
André Spiegel <spiegel@gnu.org>
parents: 31520
diff changeset
34
31385
b1e1a94dfc0a (vc-sccs-latest-on-branch-p): Always return t; we
Gerd Moellmann <gerd@gnu.org>
parents:
diff changeset
35 (defcustom vc-sccs-register-switches nil
31477
1cfec89307a6 Doc fixes.
Dave Love <fx@gnu.org>
parents: 31404
diff changeset
36 "*Extra switches for registering a file in SCCS.
1cfec89307a6 Doc fixes.
Dave Love <fx@gnu.org>
parents: 31404
diff changeset
37 A string or list of strings passed to the checkin program by
31385
b1e1a94dfc0a (vc-sccs-latest-on-branch-p): Always return t; we
Gerd Moellmann <gerd@gnu.org>
parents:
diff changeset
38 \\[vc-sccs-register]."
b1e1a94dfc0a (vc-sccs-latest-on-branch-p): Always return t; we
Gerd Moellmann <gerd@gnu.org>
parents:
diff changeset
39 :type '(choice (const :tag "None" nil)
b1e1a94dfc0a (vc-sccs-latest-on-branch-p): Always return t; we
Gerd Moellmann <gerd@gnu.org>
parents:
diff changeset
40 (string :tag "Argument String")
b1e1a94dfc0a (vc-sccs-latest-on-branch-p): Always return t; we
Gerd Moellmann <gerd@gnu.org>
parents:
diff changeset
41 (repeat :tag "Argument List"
b1e1a94dfc0a (vc-sccs-latest-on-branch-p): Always return t; we
Gerd Moellmann <gerd@gnu.org>
parents:
diff changeset
42 :value ("")
b1e1a94dfc0a (vc-sccs-latest-on-branch-p): Always return t; we
Gerd Moellmann <gerd@gnu.org>
parents:
diff changeset
43 string))
31477
1cfec89307a6 Doc fixes.
Dave Love <fx@gnu.org>
parents: 31404
diff changeset
44 :version "21.1"
31385
b1e1a94dfc0a (vc-sccs-latest-on-branch-p): Always return t; we
Gerd Moellmann <gerd@gnu.org>
parents:
diff changeset
45 :group 'vc)
b1e1a94dfc0a (vc-sccs-latest-on-branch-p): Always return t; we
Gerd Moellmann <gerd@gnu.org>
parents:
diff changeset
46
b1e1a94dfc0a (vc-sccs-latest-on-branch-p): Always return t; we
Gerd Moellmann <gerd@gnu.org>
parents:
diff changeset
47 (defcustom vc-sccs-header (or (cdr (assoc 'SCCS vc-header-alist)) '("%W%"))
b1e1a94dfc0a (vc-sccs-latest-on-branch-p): Always return t; we
Gerd Moellmann <gerd@gnu.org>
parents:
diff changeset
48 "*Header keywords to be inserted by `vc-insert-headers'."
35179
1b423e7eb1eb (vc-sccs-header): Fix :type.
Dave Love <fx@gnu.org>
parents: 35134
diff changeset
49 :type '(repeat string)
31385
b1e1a94dfc0a (vc-sccs-latest-on-branch-p): Always return t; we
Gerd Moellmann <gerd@gnu.org>
parents:
diff changeset
50 :group 'vc)
b1e1a94dfc0a (vc-sccs-latest-on-branch-p): Always return t; we
Gerd Moellmann <gerd@gnu.org>
parents:
diff changeset
51
b1e1a94dfc0a (vc-sccs-latest-on-branch-p): Always return t; we
Gerd Moellmann <gerd@gnu.org>
parents:
diff changeset
52 ;;;###autoload
b1e1a94dfc0a (vc-sccs-latest-on-branch-p): Always return t; we
Gerd Moellmann <gerd@gnu.org>
parents:
diff changeset
53 (defcustom vc-sccs-master-templates
b1e1a94dfc0a (vc-sccs-latest-on-branch-p): Always return t; we
Gerd Moellmann <gerd@gnu.org>
parents:
diff changeset
54 '("%sSCCS/s.%s" "%ss.%s" vc-sccs-search-project-dir)
b1e1a94dfc0a (vc-sccs-latest-on-branch-p): Always return t; we
Gerd Moellmann <gerd@gnu.org>
parents:
diff changeset
55 "*Where to look for SCCS master files.
b1e1a94dfc0a (vc-sccs-latest-on-branch-p): Always return t; we
Gerd Moellmann <gerd@gnu.org>
parents:
diff changeset
56 For a description of possible values, see `vc-check-master-templates'."
b1e1a94dfc0a (vc-sccs-latest-on-branch-p): Always return t; we
Gerd Moellmann <gerd@gnu.org>
parents:
diff changeset
57 :type '(choice (const :tag "Use standard SCCS file names"
b1e1a94dfc0a (vc-sccs-latest-on-branch-p): Always return t; we
Gerd Moellmann <gerd@gnu.org>
parents:
diff changeset
58 ("%sSCCS/s.%s" "%ss.%s" vc-sccs-search-project-dir))
b1e1a94dfc0a (vc-sccs-latest-on-branch-p): Always return t; we
Gerd Moellmann <gerd@gnu.org>
parents:
diff changeset
59 (repeat :tag "User-specified"
b1e1a94dfc0a (vc-sccs-latest-on-branch-p): Always return t; we
Gerd Moellmann <gerd@gnu.org>
parents:
diff changeset
60 (choice string
b1e1a94dfc0a (vc-sccs-latest-on-branch-p): Always return t; we
Gerd Moellmann <gerd@gnu.org>
parents:
diff changeset
61 function)))
31477
1cfec89307a6 Doc fixes.
Dave Love <fx@gnu.org>
parents: 31404
diff changeset
62 :version "21.1"
31385
b1e1a94dfc0a (vc-sccs-latest-on-branch-p): Always return t; we
Gerd Moellmann <gerd@gnu.org>
parents:
diff changeset
63 :group 'vc)
b1e1a94dfc0a (vc-sccs-latest-on-branch-p): Always return t; we
Gerd Moellmann <gerd@gnu.org>
parents:
diff changeset
64
33560
da206bbad86b Functions reordered.
André Spiegel <spiegel@gnu.org>
parents: 31520
diff changeset
65
da206bbad86b Functions reordered.
André Spiegel <spiegel@gnu.org>
parents: 31520
diff changeset
66 ;;;
da206bbad86b Functions reordered.
André Spiegel <spiegel@gnu.org>
parents: 31520
diff changeset
67 ;;; Internal variables
da206bbad86b Functions reordered.
André Spiegel <spiegel@gnu.org>
parents: 31520
diff changeset
68 ;;;
da206bbad86b Functions reordered.
André Spiegel <spiegel@gnu.org>
parents: 31520
diff changeset
69
31404
f2ab9420390f 2000-09-05 Stefan Monnier <monnier@cs.yale.edu>
Stefan Monnier <monnier@iro.umontreal.ca>
parents: 31385
diff changeset
70 (defconst vc-sccs-name-assoc-file "VC-names")
f2ab9420390f 2000-09-05 Stefan Monnier <monnier@cs.yale.edu>
Stefan Monnier <monnier@iro.umontreal.ca>
parents: 31385
diff changeset
71
33560
da206bbad86b Functions reordered.
André Spiegel <spiegel@gnu.org>
parents: 31520
diff changeset
72
da206bbad86b Functions reordered.
André Spiegel <spiegel@gnu.org>
parents: 31520
diff changeset
73 ;;;
da206bbad86b Functions reordered.
André Spiegel <spiegel@gnu.org>
parents: 31520
diff changeset
74 ;;; State-querying functions
da206bbad86b Functions reordered.
André Spiegel <spiegel@gnu.org>
parents: 31520
diff changeset
75 ;;;
da206bbad86b Functions reordered.
André Spiegel <spiegel@gnu.org>
parents: 31520
diff changeset
76
31385
b1e1a94dfc0a (vc-sccs-latest-on-branch-p): Always return t; we
Gerd Moellmann <gerd@gnu.org>
parents:
diff changeset
77 ;;;###autoload
b1e1a94dfc0a (vc-sccs-latest-on-branch-p): Always return t; we
Gerd Moellmann <gerd@gnu.org>
parents:
diff changeset
78 (progn (defun vc-sccs-registered (f) (vc-default-registered 'SCCS f)))
b1e1a94dfc0a (vc-sccs-latest-on-branch-p): Always return t; we
Gerd Moellmann <gerd@gnu.org>
parents:
diff changeset
79
b1e1a94dfc0a (vc-sccs-latest-on-branch-p): Always return t; we
Gerd Moellmann <gerd@gnu.org>
parents:
diff changeset
80 (defun vc-sccs-state (file)
b1e1a94dfc0a (vc-sccs-latest-on-branch-p): Always return t; we
Gerd Moellmann <gerd@gnu.org>
parents:
diff changeset
81 "SCCS-specific function to compute the version control state."
b1e1a94dfc0a (vc-sccs-latest-on-branch-p): Always return t; we
Gerd Moellmann <gerd@gnu.org>
parents:
diff changeset
82 (with-temp-buffer
b1e1a94dfc0a (vc-sccs-latest-on-branch-p): Always return t; we
Gerd Moellmann <gerd@gnu.org>
parents:
diff changeset
83 (if (vc-insert-file (vc-sccs-lock-file file))
b1e1a94dfc0a (vc-sccs-latest-on-branch-p): Always return t; we
Gerd Moellmann <gerd@gnu.org>
parents:
diff changeset
84 (let* ((locks (vc-sccs-parse-locks))
b1e1a94dfc0a (vc-sccs-latest-on-branch-p): Always return t; we
Gerd Moellmann <gerd@gnu.org>
parents:
diff changeset
85 (workfile-version (vc-workfile-version file))
b1e1a94dfc0a (vc-sccs-latest-on-branch-p): Always return t; we
Gerd Moellmann <gerd@gnu.org>
parents:
diff changeset
86 (locking-user (cdr (assoc workfile-version locks))))
b1e1a94dfc0a (vc-sccs-latest-on-branch-p): Always return t; we
Gerd Moellmann <gerd@gnu.org>
parents:
diff changeset
87 (if (not locking-user)
b1e1a94dfc0a (vc-sccs-latest-on-branch-p): Always return t; we
Gerd Moellmann <gerd@gnu.org>
parents:
diff changeset
88 (if (vc-workfile-unchanged-p file)
b1e1a94dfc0a (vc-sccs-latest-on-branch-p): Always return t; we
Gerd Moellmann <gerd@gnu.org>
parents:
diff changeset
89 'up-to-date
b1e1a94dfc0a (vc-sccs-latest-on-branch-p): Always return t; we
Gerd Moellmann <gerd@gnu.org>
parents:
diff changeset
90 'unlocked-changes)
b1e1a94dfc0a (vc-sccs-latest-on-branch-p): Always return t; we
Gerd Moellmann <gerd@gnu.org>
parents:
diff changeset
91 (if (string= locking-user (vc-user-login-name))
b1e1a94dfc0a (vc-sccs-latest-on-branch-p): Always return t; we
Gerd Moellmann <gerd@gnu.org>
parents:
diff changeset
92 'edited
b1e1a94dfc0a (vc-sccs-latest-on-branch-p): Always return t; we
Gerd Moellmann <gerd@gnu.org>
parents:
diff changeset
93 locking-user)))
b1e1a94dfc0a (vc-sccs-latest-on-branch-p): Always return t; we
Gerd Moellmann <gerd@gnu.org>
parents:
diff changeset
94 'up-to-date)))
b1e1a94dfc0a (vc-sccs-latest-on-branch-p): Always return t; we
Gerd Moellmann <gerd@gnu.org>
parents:
diff changeset
95
b1e1a94dfc0a (vc-sccs-latest-on-branch-p): Always return t; we
Gerd Moellmann <gerd@gnu.org>
parents:
diff changeset
96 (defun vc-sccs-state-heuristic (file)
b1e1a94dfc0a (vc-sccs-latest-on-branch-p): Always return t; we
Gerd Moellmann <gerd@gnu.org>
parents:
diff changeset
97 "SCCS-specific state heuristic."
b1e1a94dfc0a (vc-sccs-latest-on-branch-p): Always return t; we
Gerd Moellmann <gerd@gnu.org>
parents:
diff changeset
98 (if (not (vc-mistrust-permissions file))
b1e1a94dfc0a (vc-sccs-latest-on-branch-p): Always return t; we
Gerd Moellmann <gerd@gnu.org>
parents:
diff changeset
99 ;; This implementation assumes that any file which is under version
b1e1a94dfc0a (vc-sccs-latest-on-branch-p): Always return t; we
Gerd Moellmann <gerd@gnu.org>
parents:
diff changeset
100 ;; control and has -rw-r--r-- is locked by its owner. This is true
b1e1a94dfc0a (vc-sccs-latest-on-branch-p): Always return t; we
Gerd Moellmann <gerd@gnu.org>
parents:
diff changeset
101 ;; for both RCS and SCCS, which keep unlocked files at -r--r--r--.
b1e1a94dfc0a (vc-sccs-latest-on-branch-p): Always return t; we
Gerd Moellmann <gerd@gnu.org>
parents:
diff changeset
102 ;; We have to be careful not to exclude files with execute bits on;
b1e1a94dfc0a (vc-sccs-latest-on-branch-p): Always return t; we
Gerd Moellmann <gerd@gnu.org>
parents:
diff changeset
103 ;; scripts can be under version control too. Also, we must ignore the
b1e1a94dfc0a (vc-sccs-latest-on-branch-p): Always return t; we
Gerd Moellmann <gerd@gnu.org>
parents:
diff changeset
104 ;; group-read and other-read bits, since paranoid users turn them off.
b1e1a94dfc0a (vc-sccs-latest-on-branch-p): Always return t; we
Gerd Moellmann <gerd@gnu.org>
parents:
diff changeset
105 (let* ((attributes (file-attributes file))
b1e1a94dfc0a (vc-sccs-latest-on-branch-p): Always return t; we
Gerd Moellmann <gerd@gnu.org>
parents:
diff changeset
106 (owner-uid (nth 2 attributes))
b1e1a94dfc0a (vc-sccs-latest-on-branch-p): Always return t; we
Gerd Moellmann <gerd@gnu.org>
parents:
diff changeset
107 (permissions (nth 8 attributes)))
b1e1a94dfc0a (vc-sccs-latest-on-branch-p): Always return t; we
Gerd Moellmann <gerd@gnu.org>
parents:
diff changeset
108 (if (string-match ".r-..-..-." permissions)
b1e1a94dfc0a (vc-sccs-latest-on-branch-p): Always return t; we
Gerd Moellmann <gerd@gnu.org>
parents:
diff changeset
109 'up-to-date
b1e1a94dfc0a (vc-sccs-latest-on-branch-p): Always return t; we
Gerd Moellmann <gerd@gnu.org>
parents:
diff changeset
110 (if (string-match ".rw..-..-." permissions)
b1e1a94dfc0a (vc-sccs-latest-on-branch-p): Always return t; we
Gerd Moellmann <gerd@gnu.org>
parents:
diff changeset
111 (if (file-ownership-preserved-p file)
b1e1a94dfc0a (vc-sccs-latest-on-branch-p): Always return t; we
Gerd Moellmann <gerd@gnu.org>
parents:
diff changeset
112 'edited
b1e1a94dfc0a (vc-sccs-latest-on-branch-p): Always return t; we
Gerd Moellmann <gerd@gnu.org>
parents:
diff changeset
113 (vc-user-login-name owner-uid))
31477
1cfec89307a6 Doc fixes.
Dave Love <fx@gnu.org>
parents: 31404
diff changeset
114 ;; Strange permissions.
31385
b1e1a94dfc0a (vc-sccs-latest-on-branch-p): Always return t; we
Gerd Moellmann <gerd@gnu.org>
parents:
diff changeset
115 ;; Fall through to real state computation.
b1e1a94dfc0a (vc-sccs-latest-on-branch-p): Always return t; we
Gerd Moellmann <gerd@gnu.org>
parents:
diff changeset
116 (vc-sccs-state file)))
b1e1a94dfc0a (vc-sccs-latest-on-branch-p): Always return t; we
Gerd Moellmann <gerd@gnu.org>
parents:
diff changeset
117 (vc-sccs-state file))))
b1e1a94dfc0a (vc-sccs-latest-on-branch-p): Always return t; we
Gerd Moellmann <gerd@gnu.org>
parents:
diff changeset
118
b1e1a94dfc0a (vc-sccs-latest-on-branch-p): Always return t; we
Gerd Moellmann <gerd@gnu.org>
parents:
diff changeset
119 (defun vc-sccs-workfile-version (file)
b1e1a94dfc0a (vc-sccs-latest-on-branch-p): Always return t; we
Gerd Moellmann <gerd@gnu.org>
parents:
diff changeset
120 "SCCS-specific version of `vc-workfile-version'."
b1e1a94dfc0a (vc-sccs-latest-on-branch-p): Always return t; we
Gerd Moellmann <gerd@gnu.org>
parents:
diff changeset
121 (with-temp-buffer
b1e1a94dfc0a (vc-sccs-latest-on-branch-p): Always return t; we
Gerd Moellmann <gerd@gnu.org>
parents:
diff changeset
122 (vc-insert-file (vc-name file) "^\001e")
b1e1a94dfc0a (vc-sccs-latest-on-branch-p): Always return t; we
Gerd Moellmann <gerd@gnu.org>
parents:
diff changeset
123 (vc-parse-buffer "^\001d D \\([^ ]+\\)" 1)))
b1e1a94dfc0a (vc-sccs-latest-on-branch-p): Always return t; we
Gerd Moellmann <gerd@gnu.org>
parents:
diff changeset
124
31477
1cfec89307a6 Doc fixes.
Dave Love <fx@gnu.org>
parents: 31404
diff changeset
125 (defun vc-sccs-checkout-model (file)
31385
b1e1a94dfc0a (vc-sccs-latest-on-branch-p): Always return t; we
Gerd Moellmann <gerd@gnu.org>
parents:
diff changeset
126 "SCCS-specific version of `vc-checkout-model'."
b1e1a94dfc0a (vc-sccs-latest-on-branch-p): Always return t; we
Gerd Moellmann <gerd@gnu.org>
parents:
diff changeset
127 'locking)
b1e1a94dfc0a (vc-sccs-latest-on-branch-p): Always return t; we
Gerd Moellmann <gerd@gnu.org>
parents:
diff changeset
128
b1e1a94dfc0a (vc-sccs-latest-on-branch-p): Always return t; we
Gerd Moellmann <gerd@gnu.org>
parents:
diff changeset
129 (defun vc-sccs-workfile-unchanged-p (file)
b1e1a94dfc0a (vc-sccs-latest-on-branch-p): Always return t; we
Gerd Moellmann <gerd@gnu.org>
parents:
diff changeset
130 "SCCS-specific implementation of vc-workfile-unchanged-p."
b1e1a94dfc0a (vc-sccs-latest-on-branch-p): Always return t; we
Gerd Moellmann <gerd@gnu.org>
parents:
diff changeset
131 (apply 'vc-do-command nil 1 "vcdiff" (vc-name file)
31477
1cfec89307a6 Doc fixes.
Dave Love <fx@gnu.org>
parents: 31404
diff changeset
132 (list "--brief" "-q"
31385
b1e1a94dfc0a (vc-sccs-latest-on-branch-p): Always return t; we
Gerd Moellmann <gerd@gnu.org>
parents:
diff changeset
133 (concat "-r" (vc-workfile-version file)))))
b1e1a94dfc0a (vc-sccs-latest-on-branch-p): Always return t; we
Gerd Moellmann <gerd@gnu.org>
parents:
diff changeset
134
b1e1a94dfc0a (vc-sccs-latest-on-branch-p): Always return t; we
Gerd Moellmann <gerd@gnu.org>
parents:
diff changeset
135
33560
da206bbad86b Functions reordered.
André Spiegel <spiegel@gnu.org>
parents: 31520
diff changeset
136 ;;;
da206bbad86b Functions reordered.
André Spiegel <spiegel@gnu.org>
parents: 31520
diff changeset
137 ;;; State-changing functions
da206bbad86b Functions reordered.
André Spiegel <spiegel@gnu.org>
parents: 31520
diff changeset
138 ;;;
31385
b1e1a94dfc0a (vc-sccs-latest-on-branch-p): Always return t; we
Gerd Moellmann <gerd@gnu.org>
parents:
diff changeset
139
b1e1a94dfc0a (vc-sccs-latest-on-branch-p): Always return t; we
Gerd Moellmann <gerd@gnu.org>
parents:
diff changeset
140 (defun vc-sccs-register (file &optional rev comment)
b1e1a94dfc0a (vc-sccs-latest-on-branch-p): Always return t; we
Gerd Moellmann <gerd@gnu.org>
parents:
diff changeset
141 "Register FILE into the SCCS version-control system.
b1e1a94dfc0a (vc-sccs-latest-on-branch-p): Always return t; we
Gerd Moellmann <gerd@gnu.org>
parents:
diff changeset
142 REV is the optional revision number for the file. COMMENT can be used
b1e1a94dfc0a (vc-sccs-latest-on-branch-p): Always return t; we
Gerd Moellmann <gerd@gnu.org>
parents:
diff changeset
143 to provide an initial description of FILE.
b1e1a94dfc0a (vc-sccs-latest-on-branch-p): Always return t; we
Gerd Moellmann <gerd@gnu.org>
parents:
diff changeset
144
b1e1a94dfc0a (vc-sccs-latest-on-branch-p): Always return t; we
Gerd Moellmann <gerd@gnu.org>
parents:
diff changeset
145 `vc-register-switches' and `vc-sccs-register-switches' are passed to
b1e1a94dfc0a (vc-sccs-latest-on-branch-p): Always return t; we
Gerd Moellmann <gerd@gnu.org>
parents:
diff changeset
146 the SCCS command (in that order).
b1e1a94dfc0a (vc-sccs-latest-on-branch-p): Always return t; we
Gerd Moellmann <gerd@gnu.org>
parents:
diff changeset
147
b1e1a94dfc0a (vc-sccs-latest-on-branch-p): Always return t; we
Gerd Moellmann <gerd@gnu.org>
parents:
diff changeset
148 Automatically retrieve a read-only version of the file with keywords
b1e1a94dfc0a (vc-sccs-latest-on-branch-p): Always return t; we
Gerd Moellmann <gerd@gnu.org>
parents:
diff changeset
149 expanded if `vc-keep-workfiles' is non-nil, otherwise, delete the workfile."
b1e1a94dfc0a (vc-sccs-latest-on-branch-p): Always return t; we
Gerd Moellmann <gerd@gnu.org>
parents:
diff changeset
150 (let* ((switches (list
b1e1a94dfc0a (vc-sccs-latest-on-branch-p): Always return t; we
Gerd Moellmann <gerd@gnu.org>
parents:
diff changeset
151 (if (stringp vc-register-switches)
b1e1a94dfc0a (vc-sccs-latest-on-branch-p): Always return t; we
Gerd Moellmann <gerd@gnu.org>
parents:
diff changeset
152 (list vc-register-switches)
b1e1a94dfc0a (vc-sccs-latest-on-branch-p): Always return t; we
Gerd Moellmann <gerd@gnu.org>
parents:
diff changeset
153 vc-register-switches)
b1e1a94dfc0a (vc-sccs-latest-on-branch-p): Always return t; we
Gerd Moellmann <gerd@gnu.org>
parents:
diff changeset
154 (if (stringp vc-sccs-register-switches)
b1e1a94dfc0a (vc-sccs-latest-on-branch-p): Always return t; we
Gerd Moellmann <gerd@gnu.org>
parents:
diff changeset
155 (list vc-sccs-register-switches)
b1e1a94dfc0a (vc-sccs-latest-on-branch-p): Always return t; we
Gerd Moellmann <gerd@gnu.org>
parents:
diff changeset
156 vc-sccs-register-switches)))
b1e1a94dfc0a (vc-sccs-latest-on-branch-p): Always return t; we
Gerd Moellmann <gerd@gnu.org>
parents:
diff changeset
157 (dirname (or (file-name-directory file) ""))
b1e1a94dfc0a (vc-sccs-latest-on-branch-p): Always return t; we
Gerd Moellmann <gerd@gnu.org>
parents:
diff changeset
158 (basename (file-name-nondirectory file))
b1e1a94dfc0a (vc-sccs-latest-on-branch-p): Always return t; we
Gerd Moellmann <gerd@gnu.org>
parents:
diff changeset
159 (project-file (vc-sccs-search-project-dir dirname basename)))
b1e1a94dfc0a (vc-sccs-latest-on-branch-p): Always return t; we
Gerd Moellmann <gerd@gnu.org>
parents:
diff changeset
160 (let ((vc-name
b1e1a94dfc0a (vc-sccs-latest-on-branch-p): Always return t; we
Gerd Moellmann <gerd@gnu.org>
parents:
diff changeset
161 (or project-file
b1e1a94dfc0a (vc-sccs-latest-on-branch-p): Always return t; we
Gerd Moellmann <gerd@gnu.org>
parents:
diff changeset
162 (format (car vc-sccs-master-templates) dirname basename)))|)
31477
1cfec89307a6 Doc fixes.
Dave Love <fx@gnu.org>
parents: 31404
diff changeset
163 (apply 'vc-do-command nil 0 "admin" nil
31385
b1e1a94dfc0a (vc-sccs-latest-on-branch-p): Always return t; we
Gerd Moellmann <gerd@gnu.org>
parents:
diff changeset
164 (and rev (concat "-r" rev))
b1e1a94dfc0a (vc-sccs-latest-on-branch-p): Always return t; we
Gerd Moellmann <gerd@gnu.org>
parents:
diff changeset
165 "-fb"
b1e1a94dfc0a (vc-sccs-latest-on-branch-p): Always return t; we
Gerd Moellmann <gerd@gnu.org>
parents:
diff changeset
166 (concat "-i" file)
b1e1a94dfc0a (vc-sccs-latest-on-branch-p): Always return t; we
Gerd Moellmann <gerd@gnu.org>
parents:
diff changeset
167 (and comment (concat "-y" comment))
b1e1a94dfc0a (vc-sccs-latest-on-branch-p): Always return t; we
Gerd Moellmann <gerd@gnu.org>
parents:
diff changeset
168 vc-name
b1e1a94dfc0a (vc-sccs-latest-on-branch-p): Always return t; we
Gerd Moellmann <gerd@gnu.org>
parents:
diff changeset
169 switches))
b1e1a94dfc0a (vc-sccs-latest-on-branch-p): Always return t; we
Gerd Moellmann <gerd@gnu.org>
parents:
diff changeset
170 (delete-file file)
b1e1a94dfc0a (vc-sccs-latest-on-branch-p): Always return t; we
Gerd Moellmann <gerd@gnu.org>
parents:
diff changeset
171 (if vc-keep-workfiles
b1e1a94dfc0a (vc-sccs-latest-on-branch-p): Always return t; we
Gerd Moellmann <gerd@gnu.org>
parents:
diff changeset
172 (vc-do-command nil 0 "get" (vc-name file)))))
b1e1a94dfc0a (vc-sccs-latest-on-branch-p): Always return t; we
Gerd Moellmann <gerd@gnu.org>
parents:
diff changeset
173
33560
da206bbad86b Functions reordered.
André Spiegel <spiegel@gnu.org>
parents: 31520
diff changeset
174 (defun vc-sccs-responsible-p (file)
da206bbad86b Functions reordered.
André Spiegel <spiegel@gnu.org>
parents: 31520
diff changeset
175 "Return non-nil if SCCS thinks it would be responsible for registering FILE."
da206bbad86b Functions reordered.
André Spiegel <spiegel@gnu.org>
parents: 31520
diff changeset
176 ;; TODO: check for all the patterns in vc-sccs-master-templates
da206bbad86b Functions reordered.
André Spiegel <spiegel@gnu.org>
parents: 31520
diff changeset
177 (or (file-directory-p (expand-file-name "SCCS" (file-name-directory file)))
da206bbad86b Functions reordered.
André Spiegel <spiegel@gnu.org>
parents: 31520
diff changeset
178 (stringp (vc-sccs-search-project-dir (or (file-name-directory file) "")
da206bbad86b Functions reordered.
André Spiegel <spiegel@gnu.org>
parents: 31520
diff changeset
179 (file-name-nondirectory file)))))
da206bbad86b Functions reordered.
André Spiegel <spiegel@gnu.org>
parents: 31520
diff changeset
180
da206bbad86b Functions reordered.
André Spiegel <spiegel@gnu.org>
parents: 31520
diff changeset
181 (defun vc-sccs-checkin (file rev comment)
da206bbad86b Functions reordered.
André Spiegel <spiegel@gnu.org>
parents: 31520
diff changeset
182 "SCCS-specific version of `vc-backend-checkin'."
da206bbad86b Functions reordered.
André Spiegel <spiegel@gnu.org>
parents: 31520
diff changeset
183 (let ((switches (if (stringp vc-checkin-switches)
da206bbad86b Functions reordered.
André Spiegel <spiegel@gnu.org>
parents: 31520
diff changeset
184 (list vc-checkin-switches)
da206bbad86b Functions reordered.
André Spiegel <spiegel@gnu.org>
parents: 31520
diff changeset
185 vc-checkin-switches)))
da206bbad86b Functions reordered.
André Spiegel <spiegel@gnu.org>
parents: 31520
diff changeset
186 (apply 'vc-do-command nil 0 "delta" (vc-name file)
da206bbad86b Functions reordered.
André Spiegel <spiegel@gnu.org>
parents: 31520
diff changeset
187 (if rev (concat "-r" rev))
da206bbad86b Functions reordered.
André Spiegel <spiegel@gnu.org>
parents: 31520
diff changeset
188 (concat "-y" comment)
da206bbad86b Functions reordered.
André Spiegel <spiegel@gnu.org>
parents: 31520
diff changeset
189 switches)
da206bbad86b Functions reordered.
André Spiegel <spiegel@gnu.org>
parents: 31520
diff changeset
190 (if vc-keep-workfiles
da206bbad86b Functions reordered.
André Spiegel <spiegel@gnu.org>
parents: 31520
diff changeset
191 (vc-do-command nil 0 "get" (vc-name file)))))
da206bbad86b Functions reordered.
André Spiegel <spiegel@gnu.org>
parents: 31520
diff changeset
192
35134
f7a5d39c26f0 (vc-sccs-latest-on-branch-p): Removed.
André Spiegel <spiegel@gnu.org>
parents: 33560
diff changeset
193 (defun vc-sccs-checkout (file &optional editable rev workfile)
31477
1cfec89307a6 Doc fixes.
Dave Love <fx@gnu.org>
parents: 31404
diff changeset
194 "Retrieve a copy of a saved version of SCCS controlled FILE into a WORKFILE.
35134
f7a5d39c26f0 (vc-sccs-latest-on-branch-p): Removed.
André Spiegel <spiegel@gnu.org>
parents: 33560
diff changeset
195 EDITABLE non-nil means that the file should be writable and
f7a5d39c26f0 (vc-sccs-latest-on-branch-p): Removed.
André Spiegel <spiegel@gnu.org>
parents: 33560
diff changeset
196 locked. REV is the revision to check out into WORKFILE."
31385
b1e1a94dfc0a (vc-sccs-latest-on-branch-p): Always return t; we
Gerd Moellmann <gerd@gnu.org>
parents:
diff changeset
197 (let ((filename (or workfile file))
b1e1a94dfc0a (vc-sccs-latest-on-branch-p): Always return t; we
Gerd Moellmann <gerd@gnu.org>
parents:
diff changeset
198 (file-buffer (get-file-buffer file))
b1e1a94dfc0a (vc-sccs-latest-on-branch-p): Always return t; we
Gerd Moellmann <gerd@gnu.org>
parents:
diff changeset
199 switches)
b1e1a94dfc0a (vc-sccs-latest-on-branch-p): Always return t; we
Gerd Moellmann <gerd@gnu.org>
parents:
diff changeset
200 (message "Checking out %s..." filename)
b1e1a94dfc0a (vc-sccs-latest-on-branch-p): Always return t; we
Gerd Moellmann <gerd@gnu.org>
parents:
diff changeset
201 (save-excursion
b1e1a94dfc0a (vc-sccs-latest-on-branch-p): Always return t; we
Gerd Moellmann <gerd@gnu.org>
parents:
diff changeset
202 ;; Change buffers to get local value of vc-checkout-switches.
b1e1a94dfc0a (vc-sccs-latest-on-branch-p): Always return t; we
Gerd Moellmann <gerd@gnu.org>
parents:
diff changeset
203 (if file-buffer (set-buffer file-buffer))
b1e1a94dfc0a (vc-sccs-latest-on-branch-p): Always return t; we
Gerd Moellmann <gerd@gnu.org>
parents:
diff changeset
204 (setq switches (if (stringp vc-checkout-switches)
b1e1a94dfc0a (vc-sccs-latest-on-branch-p): Always return t; we
Gerd Moellmann <gerd@gnu.org>
parents:
diff changeset
205 (list vc-checkout-switches)
b1e1a94dfc0a (vc-sccs-latest-on-branch-p): Always return t; we
Gerd Moellmann <gerd@gnu.org>
parents:
diff changeset
206 vc-checkout-switches))
b1e1a94dfc0a (vc-sccs-latest-on-branch-p): Always return t; we
Gerd Moellmann <gerd@gnu.org>
parents:
diff changeset
207 ;; Save this buffer's default-directory
b1e1a94dfc0a (vc-sccs-latest-on-branch-p): Always return t; we
Gerd Moellmann <gerd@gnu.org>
parents:
diff changeset
208 ;; and use save-excursion to make sure it is restored
b1e1a94dfc0a (vc-sccs-latest-on-branch-p): Always return t; we
Gerd Moellmann <gerd@gnu.org>
parents:
diff changeset
209 ;; in the same buffer it was saved in.
b1e1a94dfc0a (vc-sccs-latest-on-branch-p): Always return t; we
Gerd Moellmann <gerd@gnu.org>
parents:
diff changeset
210 (let ((default-directory default-directory))
b1e1a94dfc0a (vc-sccs-latest-on-branch-p): Always return t; we
Gerd Moellmann <gerd@gnu.org>
parents:
diff changeset
211 (save-excursion
b1e1a94dfc0a (vc-sccs-latest-on-branch-p): Always return t; we
Gerd Moellmann <gerd@gnu.org>
parents:
diff changeset
212 ;; Adjust the default-directory so that the check-out creates
b1e1a94dfc0a (vc-sccs-latest-on-branch-p): Always return t; we
Gerd Moellmann <gerd@gnu.org>
parents:
diff changeset
213 ;; the file in the right place.
b1e1a94dfc0a (vc-sccs-latest-on-branch-p): Always return t; we
Gerd Moellmann <gerd@gnu.org>
parents:
diff changeset
214 (setq default-directory (file-name-directory filename))
b1e1a94dfc0a (vc-sccs-latest-on-branch-p): Always return t; we
Gerd Moellmann <gerd@gnu.org>
parents:
diff changeset
215
b1e1a94dfc0a (vc-sccs-latest-on-branch-p): Always return t; we
Gerd Moellmann <gerd@gnu.org>
parents:
diff changeset
216 (and rev (string= rev "") (setq rev nil))
b1e1a94dfc0a (vc-sccs-latest-on-branch-p): Always return t; we
Gerd Moellmann <gerd@gnu.org>
parents:
diff changeset
217 (if workfile
b1e1a94dfc0a (vc-sccs-latest-on-branch-p): Always return t; we
Gerd Moellmann <gerd@gnu.org>
parents:
diff changeset
218 ;; Some SCCS implementations allow checking out directly to a
b1e1a94dfc0a (vc-sccs-latest-on-branch-p): Always return t; we
Gerd Moellmann <gerd@gnu.org>
parents:
diff changeset
219 ;; file using the -G option, but then some don't so use the
b1e1a94dfc0a (vc-sccs-latest-on-branch-p): Always return t; we
Gerd Moellmann <gerd@gnu.org>
parents:
diff changeset
220 ;; least common denominator approach and use the -p option
b1e1a94dfc0a (vc-sccs-latest-on-branch-p): Always return t; we
Gerd Moellmann <gerd@gnu.org>
parents:
diff changeset
221 ;; ala RCS.
b1e1a94dfc0a (vc-sccs-latest-on-branch-p): Always return t; we
Gerd Moellmann <gerd@gnu.org>
parents:
diff changeset
222 (let ((vc-modes (logior (file-modes (vc-name file))
35134
f7a5d39c26f0 (vc-sccs-latest-on-branch-p): Removed.
André Spiegel <spiegel@gnu.org>
parents: 33560
diff changeset
223 (if editable 128 0)))
31385
b1e1a94dfc0a (vc-sccs-latest-on-branch-p): Always return t; we
Gerd Moellmann <gerd@gnu.org>
parents:
diff changeset
224 (failed t))
b1e1a94dfc0a (vc-sccs-latest-on-branch-p): Always return t; we
Gerd Moellmann <gerd@gnu.org>
parents:
diff changeset
225 (unwind-protect
b1e1a94dfc0a (vc-sccs-latest-on-branch-p): Always return t; we
Gerd Moellmann <gerd@gnu.org>
parents:
diff changeset
226 (progn
b1e1a94dfc0a (vc-sccs-latest-on-branch-p): Always return t; we
Gerd Moellmann <gerd@gnu.org>
parents:
diff changeset
227 (let ((coding-system-for-read 'no-conversion)
b1e1a94dfc0a (vc-sccs-latest-on-branch-p): Always return t; we
Gerd Moellmann <gerd@gnu.org>
parents:
diff changeset
228 (coding-system-for-write 'no-conversion))
b1e1a94dfc0a (vc-sccs-latest-on-branch-p): Always return t; we
Gerd Moellmann <gerd@gnu.org>
parents:
diff changeset
229 (with-temp-file filename
b1e1a94dfc0a (vc-sccs-latest-on-branch-p): Always return t; we
Gerd Moellmann <gerd@gnu.org>
parents:
diff changeset
230 (apply 'vc-do-command
b1e1a94dfc0a (vc-sccs-latest-on-branch-p): Always return t; we
Gerd Moellmann <gerd@gnu.org>
parents:
diff changeset
231 (current-buffer) 0 "get" (vc-name file)
b1e1a94dfc0a (vc-sccs-latest-on-branch-p): Always return t; we
Gerd Moellmann <gerd@gnu.org>
parents:
diff changeset
232 "-s" ;; suppress diagnostic output
35134
f7a5d39c26f0 (vc-sccs-latest-on-branch-p): Removed.
André Spiegel <spiegel@gnu.org>
parents: 33560
diff changeset
233 (if editable "-e")
31477
1cfec89307a6 Doc fixes.
Dave Love <fx@gnu.org>
parents: 31404
diff changeset
234 "-p"
31385
b1e1a94dfc0a (vc-sccs-latest-on-branch-p): Always return t; we
Gerd Moellmann <gerd@gnu.org>
parents:
diff changeset
235 (and rev
31477
1cfec89307a6 Doc fixes.
Dave Love <fx@gnu.org>
parents: 31404
diff changeset
236 (concat "-r"
31385
b1e1a94dfc0a (vc-sccs-latest-on-branch-p): Always return t; we
Gerd Moellmann <gerd@gnu.org>
parents:
diff changeset
237 (vc-sccs-lookup-triple file rev)))
b1e1a94dfc0a (vc-sccs-latest-on-branch-p): Always return t; we
Gerd Moellmann <gerd@gnu.org>
parents:
diff changeset
238 switches)))
b1e1a94dfc0a (vc-sccs-latest-on-branch-p): Always return t; we
Gerd Moellmann <gerd@gnu.org>
parents:
diff changeset
239 (set-file-modes filename
b1e1a94dfc0a (vc-sccs-latest-on-branch-p): Always return t; we
Gerd Moellmann <gerd@gnu.org>
parents:
diff changeset
240 (logior (file-modes (vc-name file))
35134
f7a5d39c26f0 (vc-sccs-latest-on-branch-p): Removed.
André Spiegel <spiegel@gnu.org>
parents: 33560
diff changeset
241 (if editable 128 0)))
31385
b1e1a94dfc0a (vc-sccs-latest-on-branch-p): Always return t; we
Gerd Moellmann <gerd@gnu.org>
parents:
diff changeset
242 (setq failed nil))
b1e1a94dfc0a (vc-sccs-latest-on-branch-p): Always return t; we
Gerd Moellmann <gerd@gnu.org>
parents:
diff changeset
243 (and failed (file-exists-p filename)
b1e1a94dfc0a (vc-sccs-latest-on-branch-p): Always return t; we
Gerd Moellmann <gerd@gnu.org>
parents:
diff changeset
244 (delete-file filename))))
b1e1a94dfc0a (vc-sccs-latest-on-branch-p): Always return t; we
Gerd Moellmann <gerd@gnu.org>
parents:
diff changeset
245 (apply 'vc-do-command nil 0 "get" (vc-name file)
35134
f7a5d39c26f0 (vc-sccs-latest-on-branch-p): Removed.
André Spiegel <spiegel@gnu.org>
parents: 33560
diff changeset
246 (if editable "-e")
31385
b1e1a94dfc0a (vc-sccs-latest-on-branch-p): Always return t; we
Gerd Moellmann <gerd@gnu.org>
parents:
diff changeset
247 (and rev (concat "-r" (vc-sccs-lookup-triple file rev)))
31404
f2ab9420390f 2000-09-05 Stefan Monnier <monnier@cs.yale.edu>
Stefan Monnier <monnier@iro.umontreal.ca>
parents: 31385
diff changeset
248 switches)))))
f2ab9420390f 2000-09-05 Stefan Monnier <monnier@cs.yale.edu>
Stefan Monnier <monnier@iro.umontreal.ca>
parents: 31385
diff changeset
249 (message "Checking out %s...done" filename)))
31385
b1e1a94dfc0a (vc-sccs-latest-on-branch-p): Always return t; we
Gerd Moellmann <gerd@gnu.org>
parents:
diff changeset
250
33560
da206bbad86b Functions reordered.
André Spiegel <spiegel@gnu.org>
parents: 31520
diff changeset
251 (defun vc-sccs-revert (file)
da206bbad86b Functions reordered.
André Spiegel <spiegel@gnu.org>
parents: 31520
diff changeset
252 "Revert FILE to the version it was based on."
da206bbad86b Functions reordered.
André Spiegel <spiegel@gnu.org>
parents: 31520
diff changeset
253 (vc-do-command nil 0 "unget" (vc-name file))
da206bbad86b Functions reordered.
André Spiegel <spiegel@gnu.org>
parents: 31520
diff changeset
254 (vc-do-command nil 0 "get" (vc-name file))
da206bbad86b Functions reordered.
André Spiegel <spiegel@gnu.org>
parents: 31520
diff changeset
255 ;; Checking out explicit versions is not supported under SCCS, yet.
da206bbad86b Functions reordered.
André Spiegel <spiegel@gnu.org>
parents: 31520
diff changeset
256 ;; We always "revert" to the latest version; therefore
da206bbad86b Functions reordered.
André Spiegel <spiegel@gnu.org>
parents: 31520
diff changeset
257 ;; vc-workfile-version is cleared here so that it gets recomputed.
da206bbad86b Functions reordered.
André Spiegel <spiegel@gnu.org>
parents: 31520
diff changeset
258 (vc-file-setprop file 'vc-workfile-version nil))
da206bbad86b Functions reordered.
André Spiegel <spiegel@gnu.org>
parents: 31520
diff changeset
259
35134
f7a5d39c26f0 (vc-sccs-latest-on-branch-p): Removed.
André Spiegel <spiegel@gnu.org>
parents: 33560
diff changeset
260 (defun vc-sccs-cancel-version (file editable)
33560
da206bbad86b Functions reordered.
André Spiegel <spiegel@gnu.org>
parents: 31520
diff changeset
261 "Undo the most recent checkin of FILE.
35134
f7a5d39c26f0 (vc-sccs-latest-on-branch-p): Removed.
André Spiegel <spiegel@gnu.org>
parents: 33560
diff changeset
262 EDITABLE non-nil means previous version should be locked."
33560
da206bbad86b Functions reordered.
André Spiegel <spiegel@gnu.org>
parents: 31520
diff changeset
263 (vc-do-command nil 0 "rmdel"
da206bbad86b Functions reordered.
André Spiegel <spiegel@gnu.org>
parents: 31520
diff changeset
264 (vc-name file)
da206bbad86b Functions reordered.
André Spiegel <spiegel@gnu.org>
parents: 31520
diff changeset
265 (concat "-r" (vc-workfile-version file)))
da206bbad86b Functions reordered.
André Spiegel <spiegel@gnu.org>
parents: 31520
diff changeset
266 (vc-do-command nil 0 "get"
da206bbad86b Functions reordered.
André Spiegel <spiegel@gnu.org>
parents: 31520
diff changeset
267 (vc-name file)
35134
f7a5d39c26f0 (vc-sccs-latest-on-branch-p): Removed.
André Spiegel <spiegel@gnu.org>
parents: 33560
diff changeset
268 (if editable "-e")))
33560
da206bbad86b Functions reordered.
André Spiegel <spiegel@gnu.org>
parents: 31520
diff changeset
269
da206bbad86b Functions reordered.
André Spiegel <spiegel@gnu.org>
parents: 31520
diff changeset
270 (defun vc-sccs-steal-lock (file &optional rev)
da206bbad86b Functions reordered.
André Spiegel <spiegel@gnu.org>
parents: 31520
diff changeset
271 "Steal the lock on the current workfile for FILE and revision REV."
da206bbad86b Functions reordered.
André Spiegel <spiegel@gnu.org>
parents: 31520
diff changeset
272 (vc-do-command nil 0 "unget" (vc-name file) "-n" (if rev (concat "-r" rev)))
da206bbad86b Functions reordered.
André Spiegel <spiegel@gnu.org>
parents: 31520
diff changeset
273 (vc-do-command nil 0 "get" (vc-name file) "-g" (if rev (concat "-r" rev))))
da206bbad86b Functions reordered.
André Spiegel <spiegel@gnu.org>
parents: 31520
diff changeset
274
da206bbad86b Functions reordered.
André Spiegel <spiegel@gnu.org>
parents: 31520
diff changeset
275
da206bbad86b Functions reordered.
André Spiegel <spiegel@gnu.org>
parents: 31520
diff changeset
276 ;;;
da206bbad86b Functions reordered.
André Spiegel <spiegel@gnu.org>
parents: 31520
diff changeset
277 ;;; History functions
da206bbad86b Functions reordered.
André Spiegel <spiegel@gnu.org>
parents: 31520
diff changeset
278 ;;;
da206bbad86b Functions reordered.
André Spiegel <spiegel@gnu.org>
parents: 31520
diff changeset
279
da206bbad86b Functions reordered.
André Spiegel <spiegel@gnu.org>
parents: 31520
diff changeset
280 (defun vc-sccs-print-log (file)
da206bbad86b Functions reordered.
André Spiegel <spiegel@gnu.org>
parents: 31520
diff changeset
281 "Get change log associated with FILE."
da206bbad86b Functions reordered.
André Spiegel <spiegel@gnu.org>
parents: 31520
diff changeset
282 (vc-do-command t 0 "prs" (vc-name file)))
da206bbad86b Functions reordered.
André Spiegel <spiegel@gnu.org>
parents: 31520
diff changeset
283
da206bbad86b Functions reordered.
André Spiegel <spiegel@gnu.org>
parents: 31520
diff changeset
284 (defun vc-sccs-logentry-check ()
da206bbad86b Functions reordered.
André Spiegel <spiegel@gnu.org>
parents: 31520
diff changeset
285 "Check that the log entry in the current buffer is acceptable for SCCS."
da206bbad86b Functions reordered.
André Spiegel <spiegel@gnu.org>
parents: 31520
diff changeset
286 (when (>= (buffer-size) 512)
da206bbad86b Functions reordered.
André Spiegel <spiegel@gnu.org>
parents: 31520
diff changeset
287 (goto-char 512)
da206bbad86b Functions reordered.
André Spiegel <spiegel@gnu.org>
parents: 31520
diff changeset
288 (error "Log must be less than 512 characters; point is now at pos 512")))
da206bbad86b Functions reordered.
André Spiegel <spiegel@gnu.org>
parents: 31520
diff changeset
289
da206bbad86b Functions reordered.
André Spiegel <spiegel@gnu.org>
parents: 31520
diff changeset
290 (defun vc-sccs-diff (file &optional oldvers newvers)
da206bbad86b Functions reordered.
André Spiegel <spiegel@gnu.org>
parents: 31520
diff changeset
291 "Get a difference report using SCCS between two versions of FILE."
da206bbad86b Functions reordered.
André Spiegel <spiegel@gnu.org>
parents: 31520
diff changeset
292 (setq oldvers (vc-sccs-lookup-triple file oldvers))
da206bbad86b Functions reordered.
André Spiegel <spiegel@gnu.org>
parents: 31520
diff changeset
293 (setq newvers (vc-sccs-lookup-triple file newvers))
da206bbad86b Functions reordered.
André Spiegel <spiegel@gnu.org>
parents: 31520
diff changeset
294 (let* ((diff-switches-list (if (listp diff-switches)
da206bbad86b Functions reordered.
André Spiegel <spiegel@gnu.org>
parents: 31520
diff changeset
295 diff-switches
da206bbad86b Functions reordered.
André Spiegel <spiegel@gnu.org>
parents: 31520
diff changeset
296 (list diff-switches)))
da206bbad86b Functions reordered.
André Spiegel <spiegel@gnu.org>
parents: 31520
diff changeset
297 (options (append (list "-q"
da206bbad86b Functions reordered.
André Spiegel <spiegel@gnu.org>
parents: 31520
diff changeset
298 (and oldvers (concat "-r" oldvers))
da206bbad86b Functions reordered.
André Spiegel <spiegel@gnu.org>
parents: 31520
diff changeset
299 (and newvers (concat "-r" newvers)))
da206bbad86b Functions reordered.
André Spiegel <spiegel@gnu.org>
parents: 31520
diff changeset
300 diff-switches-list)))
da206bbad86b Functions reordered.
André Spiegel <spiegel@gnu.org>
parents: 31520
diff changeset
301 (apply 'vc-do-command t 1 "vcdiff" (vc-name file) options)))
da206bbad86b Functions reordered.
André Spiegel <spiegel@gnu.org>
parents: 31520
diff changeset
302
da206bbad86b Functions reordered.
André Spiegel <spiegel@gnu.org>
parents: 31520
diff changeset
303
da206bbad86b Functions reordered.
André Spiegel <spiegel@gnu.org>
parents: 31520
diff changeset
304 ;;;
da206bbad86b Functions reordered.
André Spiegel <spiegel@gnu.org>
parents: 31520
diff changeset
305 ;;; Snapshot system
da206bbad86b Functions reordered.
André Spiegel <spiegel@gnu.org>
parents: 31520
diff changeset
306 ;;;
da206bbad86b Functions reordered.
André Spiegel <spiegel@gnu.org>
parents: 31520
diff changeset
307
da206bbad86b Functions reordered.
André Spiegel <spiegel@gnu.org>
parents: 31520
diff changeset
308 (defun vc-sccs-assign-name (file name)
da206bbad86b Functions reordered.
André Spiegel <spiegel@gnu.org>
parents: 31520
diff changeset
309 "Assign to FILE's latest version a given NAME."
da206bbad86b Functions reordered.
André Spiegel <spiegel@gnu.org>
parents: 31520
diff changeset
310 (vc-sccs-add-triple name file (vc-workfile-version file)))
da206bbad86b Functions reordered.
André Spiegel <spiegel@gnu.org>
parents: 31520
diff changeset
311
da206bbad86b Functions reordered.
André Spiegel <spiegel@gnu.org>
parents: 31520
diff changeset
312
da206bbad86b Functions reordered.
André Spiegel <spiegel@gnu.org>
parents: 31520
diff changeset
313 ;;;
da206bbad86b Functions reordered.
André Spiegel <spiegel@gnu.org>
parents: 31520
diff changeset
314 ;;; Miscellaneous
da206bbad86b Functions reordered.
André Spiegel <spiegel@gnu.org>
parents: 31520
diff changeset
315 ;;;
da206bbad86b Functions reordered.
André Spiegel <spiegel@gnu.org>
parents: 31520
diff changeset
316
da206bbad86b Functions reordered.
André Spiegel <spiegel@gnu.org>
parents: 31520
diff changeset
317 (defun vc-sccs-check-headers ()
da206bbad86b Functions reordered.
André Spiegel <spiegel@gnu.org>
parents: 31520
diff changeset
318 "Check if the current file has any headers in it."
da206bbad86b Functions reordered.
André Spiegel <spiegel@gnu.org>
parents: 31520
diff changeset
319 (save-excursion
da206bbad86b Functions reordered.
André Spiegel <spiegel@gnu.org>
parents: 31520
diff changeset
320 (goto-char (point-min))
da206bbad86b Functions reordered.
André Spiegel <spiegel@gnu.org>
parents: 31520
diff changeset
321 (re-search-forward "%[A-Z]%" nil t)))
da206bbad86b Functions reordered.
André Spiegel <spiegel@gnu.org>
parents: 31520
diff changeset
322
da206bbad86b Functions reordered.
André Spiegel <spiegel@gnu.org>
parents: 31520
diff changeset
323 (defun vc-sccs-rename-file (old new)
da206bbad86b Functions reordered.
André Spiegel <spiegel@gnu.org>
parents: 31520
diff changeset
324 ;; Move the master file (using vc-rcs-master-templates).
da206bbad86b Functions reordered.
André Spiegel <spiegel@gnu.org>
parents: 31520
diff changeset
325 (vc-rename-master (vc-name old) new vc-sccs-master-templates)
da206bbad86b Functions reordered.
André Spiegel <spiegel@gnu.org>
parents: 31520
diff changeset
326 ;; Update the snapshot file.
da206bbad86b Functions reordered.
André Spiegel <spiegel@gnu.org>
parents: 31520
diff changeset
327 (with-current-buffer
da206bbad86b Functions reordered.
André Spiegel <spiegel@gnu.org>
parents: 31520
diff changeset
328 (find-file-noselect
da206bbad86b Functions reordered.
André Spiegel <spiegel@gnu.org>
parents: 31520
diff changeset
329 (expand-file-name vc-sccs-name-assoc-file
da206bbad86b Functions reordered.
André Spiegel <spiegel@gnu.org>
parents: 31520
diff changeset
330 (file-name-directory (vc-name old))))
da206bbad86b Functions reordered.
André Spiegel <spiegel@gnu.org>
parents: 31520
diff changeset
331 (goto-char (point-min))
da206bbad86b Functions reordered.
André Spiegel <spiegel@gnu.org>
parents: 31520
diff changeset
332 ;; (replace-regexp (concat ":" (regexp-quote old) "$") (concat ":" new))
da206bbad86b Functions reordered.
André Spiegel <spiegel@gnu.org>
parents: 31520
diff changeset
333 (while (re-search-forward (concat ":" (regexp-quote old) "$") nil t)
da206bbad86b Functions reordered.
André Spiegel <spiegel@gnu.org>
parents: 31520
diff changeset
334 (replace-match (concat ":" new) nil nil))
da206bbad86b Functions reordered.
André Spiegel <spiegel@gnu.org>
parents: 31520
diff changeset
335 (basic-save-buffer)
da206bbad86b Functions reordered.
André Spiegel <spiegel@gnu.org>
parents: 31520
diff changeset
336 (kill-buffer (current-buffer))))
da206bbad86b Functions reordered.
André Spiegel <spiegel@gnu.org>
parents: 31520
diff changeset
337
da206bbad86b Functions reordered.
André Spiegel <spiegel@gnu.org>
parents: 31520
diff changeset
338
da206bbad86b Functions reordered.
André Spiegel <spiegel@gnu.org>
parents: 31520
diff changeset
339 ;;;
da206bbad86b Functions reordered.
André Spiegel <spiegel@gnu.org>
parents: 31520
diff changeset
340 ;;; Internal functions
da206bbad86b Functions reordered.
André Spiegel <spiegel@gnu.org>
parents: 31520
diff changeset
341 ;;;
da206bbad86b Functions reordered.
André Spiegel <spiegel@gnu.org>
parents: 31520
diff changeset
342
da206bbad86b Functions reordered.
André Spiegel <spiegel@gnu.org>
parents: 31520
diff changeset
343 ;; This function is wrapped with `progn' so that the autoload cookie
da206bbad86b Functions reordered.
André Spiegel <spiegel@gnu.org>
parents: 31520
diff changeset
344 ;; copies the whole function itself into loaddefs.el rather than just placing
da206bbad86b Functions reordered.
André Spiegel <spiegel@gnu.org>
parents: 31520
diff changeset
345 ;; a (autoload 'vc-sccs-search-project-dir "vc-sccs") which would not
da206bbad86b Functions reordered.
André Spiegel <spiegel@gnu.org>
parents: 31520
diff changeset
346 ;; help us avoid loading vc-sccs.
da206bbad86b Functions reordered.
André Spiegel <spiegel@gnu.org>
parents: 31520
diff changeset
347 ;;;###autoload
da206bbad86b Functions reordered.
André Spiegel <spiegel@gnu.org>
parents: 31520
diff changeset
348 (progn (defun vc-sccs-search-project-dir (dirname basename)
da206bbad86b Functions reordered.
André Spiegel <spiegel@gnu.org>
parents: 31520
diff changeset
349 "Return the name of a master file in the SCCS project directory.
da206bbad86b Functions reordered.
André Spiegel <spiegel@gnu.org>
parents: 31520
diff changeset
350 Does not check whether the file exists but returns nil if it does not
da206bbad86b Functions reordered.
André Spiegel <spiegel@gnu.org>
parents: 31520
diff changeset
351 find any project directory."
da206bbad86b Functions reordered.
André Spiegel <spiegel@gnu.org>
parents: 31520
diff changeset
352 (let ((project-dir (getenv "PROJECTDIR")) dirs dir)
da206bbad86b Functions reordered.
André Spiegel <spiegel@gnu.org>
parents: 31520
diff changeset
353 (when project-dir
da206bbad86b Functions reordered.
André Spiegel <spiegel@gnu.org>
parents: 31520
diff changeset
354 (if (file-name-absolute-p project-dir)
da206bbad86b Functions reordered.
André Spiegel <spiegel@gnu.org>
parents: 31520
diff changeset
355 (setq dirs '("SCCS" ""))
da206bbad86b Functions reordered.
André Spiegel <spiegel@gnu.org>
parents: 31520
diff changeset
356 (setq dirs '("src/SCCS" "src" "source/SCCS" "source"))
da206bbad86b Functions reordered.
André Spiegel <spiegel@gnu.org>
parents: 31520
diff changeset
357 (setq project-dir (expand-file-name (concat "~" project-dir))))
da206bbad86b Functions reordered.
André Spiegel <spiegel@gnu.org>
parents: 31520
diff changeset
358 (while (and (not dir) dirs)
da206bbad86b Functions reordered.
André Spiegel <spiegel@gnu.org>
parents: 31520
diff changeset
359 (setq dir (expand-file-name (car dirs) project-dir))
da206bbad86b Functions reordered.
André Spiegel <spiegel@gnu.org>
parents: 31520
diff changeset
360 (unless (file-directory-p dir)
da206bbad86b Functions reordered.
André Spiegel <spiegel@gnu.org>
parents: 31520
diff changeset
361 (setq dir nil)
da206bbad86b Functions reordered.
André Spiegel <spiegel@gnu.org>
parents: 31520
diff changeset
362 (setq dirs (cdr dirs))))
da206bbad86b Functions reordered.
André Spiegel <spiegel@gnu.org>
parents: 31520
diff changeset
363 (and dir (expand-file-name (concat "s." basename) dir))))))
da206bbad86b Functions reordered.
André Spiegel <spiegel@gnu.org>
parents: 31520
diff changeset
364
da206bbad86b Functions reordered.
André Spiegel <spiegel@gnu.org>
parents: 31520
diff changeset
365 (defun vc-sccs-lock-file (file)
da206bbad86b Functions reordered.
André Spiegel <spiegel@gnu.org>
parents: 31520
diff changeset
366 "Generate lock file name corresponding to FILE."
da206bbad86b Functions reordered.
André Spiegel <spiegel@gnu.org>
parents: 31520
diff changeset
367 (let ((master (vc-name file)))
da206bbad86b Functions reordered.
André Spiegel <spiegel@gnu.org>
parents: 31520
diff changeset
368 (and
da206bbad86b Functions reordered.
André Spiegel <spiegel@gnu.org>
parents: 31520
diff changeset
369 master
da206bbad86b Functions reordered.
André Spiegel <spiegel@gnu.org>
parents: 31520
diff changeset
370 (string-match "\\(.*/\\)\\(s\\.\\)\\(.*\\)" master)
da206bbad86b Functions reordered.
André Spiegel <spiegel@gnu.org>
parents: 31520
diff changeset
371 (replace-match "p." t t master 2))))
da206bbad86b Functions reordered.
André Spiegel <spiegel@gnu.org>
parents: 31520
diff changeset
372
da206bbad86b Functions reordered.
André Spiegel <spiegel@gnu.org>
parents: 31520
diff changeset
373 (defun vc-sccs-parse-locks ()
da206bbad86b Functions reordered.
André Spiegel <spiegel@gnu.org>
parents: 31520
diff changeset
374 "Parse SCCS locks in current buffer.
da206bbad86b Functions reordered.
André Spiegel <spiegel@gnu.org>
parents: 31520
diff changeset
375 The result is a list of the form ((VERSION . USER) (VERSION . USER) ...)."
da206bbad86b Functions reordered.
André Spiegel <spiegel@gnu.org>
parents: 31520
diff changeset
376 (let (master-locks)
da206bbad86b Functions reordered.
André Spiegel <spiegel@gnu.org>
parents: 31520
diff changeset
377 (goto-char (point-min))
da206bbad86b Functions reordered.
André Spiegel <spiegel@gnu.org>
parents: 31520
diff changeset
378 (while (re-search-forward "^\\([0-9.]+\\) [0-9.]+ \\([^ ]+\\) .*\n?"
da206bbad86b Functions reordered.
André Spiegel <spiegel@gnu.org>
parents: 31520
diff changeset
379 nil t)
da206bbad86b Functions reordered.
André Spiegel <spiegel@gnu.org>
parents: 31520
diff changeset
380 (setq master-locks
da206bbad86b Functions reordered.
André Spiegel <spiegel@gnu.org>
parents: 31520
diff changeset
381 (cons (cons (match-string 1) (match-string 2)) master-locks)))
da206bbad86b Functions reordered.
André Spiegel <spiegel@gnu.org>
parents: 31520
diff changeset
382 ;; FIXME: is it really necessary to reverse ?
da206bbad86b Functions reordered.
André Spiegel <spiegel@gnu.org>
parents: 31520
diff changeset
383 (nreverse master-locks)))
da206bbad86b Functions reordered.
André Spiegel <spiegel@gnu.org>
parents: 31520
diff changeset
384
da206bbad86b Functions reordered.
André Spiegel <spiegel@gnu.org>
parents: 31520
diff changeset
385 (defun vc-sccs-add-triple (name file rev)
da206bbad86b Functions reordered.
André Spiegel <spiegel@gnu.org>
parents: 31520
diff changeset
386 (with-current-buffer
da206bbad86b Functions reordered.
André Spiegel <spiegel@gnu.org>
parents: 31520
diff changeset
387 (find-file-noselect
da206bbad86b Functions reordered.
André Spiegel <spiegel@gnu.org>
parents: 31520
diff changeset
388 (expand-file-name vc-sccs-name-assoc-file
da206bbad86b Functions reordered.
André Spiegel <spiegel@gnu.org>
parents: 31520
diff changeset
389 (file-name-directory (vc-name file))))
da206bbad86b Functions reordered.
André Spiegel <spiegel@gnu.org>
parents: 31520
diff changeset
390 (goto-char (point-max))
da206bbad86b Functions reordered.
André Spiegel <spiegel@gnu.org>
parents: 31520
diff changeset
391 (insert name "\t:\t" file "\t" rev "\n")
da206bbad86b Functions reordered.
André Spiegel <spiegel@gnu.org>
parents: 31520
diff changeset
392 (basic-save-buffer)
da206bbad86b Functions reordered.
André Spiegel <spiegel@gnu.org>
parents: 31520
diff changeset
393 (kill-buffer (current-buffer))))
da206bbad86b Functions reordered.
André Spiegel <spiegel@gnu.org>
parents: 31520
diff changeset
394
da206bbad86b Functions reordered.
André Spiegel <spiegel@gnu.org>
parents: 31520
diff changeset
395 (defun vc-sccs-lookup-triple (file name)
da206bbad86b Functions reordered.
André Spiegel <spiegel@gnu.org>
parents: 31520
diff changeset
396 "Return the numeric version corresponding to a named snapshot of FILE.
da206bbad86b Functions reordered.
André Spiegel <spiegel@gnu.org>
parents: 31520
diff changeset
397 If NAME is nil or a version number string it's just passed through."
da206bbad86b Functions reordered.
André Spiegel <spiegel@gnu.org>
parents: 31520
diff changeset
398 (if (or (null name)
da206bbad86b Functions reordered.
André Spiegel <spiegel@gnu.org>
parents: 31520
diff changeset
399 (let ((firstchar (aref name 0)))
da206bbad86b Functions reordered.
André Spiegel <spiegel@gnu.org>
parents: 31520
diff changeset
400 (and (>= firstchar ?0) (<= firstchar ?9))))
da206bbad86b Functions reordered.
André Spiegel <spiegel@gnu.org>
parents: 31520
diff changeset
401 name
da206bbad86b Functions reordered.
André Spiegel <spiegel@gnu.org>
parents: 31520
diff changeset
402 (with-temp-buffer
da206bbad86b Functions reordered.
André Spiegel <spiegel@gnu.org>
parents: 31520
diff changeset
403 (vc-insert-file
da206bbad86b Functions reordered.
André Spiegel <spiegel@gnu.org>
parents: 31520
diff changeset
404 (expand-file-name vc-sccs-name-assoc-file
da206bbad86b Functions reordered.
André Spiegel <spiegel@gnu.org>
parents: 31520
diff changeset
405 (file-name-directory (vc-name file))))
da206bbad86b Functions reordered.
André Spiegel <spiegel@gnu.org>
parents: 31520
diff changeset
406 (vc-parse-buffer (concat name "\t:\t" file "\t\\(.+\\)") 1))))
31385
b1e1a94dfc0a (vc-sccs-latest-on-branch-p): Always return t; we
Gerd Moellmann <gerd@gnu.org>
parents:
diff changeset
407
b1e1a94dfc0a (vc-sccs-latest-on-branch-p): Always return t; we
Gerd Moellmann <gerd@gnu.org>
parents:
diff changeset
408 (provide 'vc-sccs)
b1e1a94dfc0a (vc-sccs-latest-on-branch-p): Always return t; we
Gerd Moellmann <gerd@gnu.org>
parents:
diff changeset
409
b1e1a94dfc0a (vc-sccs-latest-on-branch-p): Always return t; we
Gerd Moellmann <gerd@gnu.org>
parents:
diff changeset
410 ;;; vc-sccs.el ends here
33560
da206bbad86b Functions reordered.
André Spiegel <spiegel@gnu.org>
parents: 31520
diff changeset
411
da206bbad86b Functions reordered.
André Spiegel <spiegel@gnu.org>
parents: 31520
diff changeset
412
da206bbad86b Functions reordered.
André Spiegel <spiegel@gnu.org>
parents: 31520
diff changeset
413