comparison lisp/vc.el @ 32310:bb71607dc3db

(vc-version-diff): diff-switches can be a list.
author Stefan Monnier <monnier@iro.umontreal.ca>
date Sun, 08 Oct 2000 19:12:52 +0000
parents 921a2e8fa97e
children f91ef1141a75
comparison
equal deleted inserted replaced
32309:bb96b2ece52b 32310:bb71607dc3db
3 ;; Copyright (C) 1992,93,94,95,96,97,98,2000 Free Software Foundation, Inc. 3 ;; Copyright (C) 1992,93,94,95,96,97,98,2000 Free Software Foundation, Inc.
4 4
5 ;; Author: FSF (see below for full credits) 5 ;; Author: FSF (see below for full credits)
6 ;; Maintainer: Andre Spiegel <spiegel@gnu.org> 6 ;; Maintainer: Andre Spiegel <spiegel@gnu.org>
7 7
8 ;; $Id: vc.el,v 1.277 2000/10/04 09:48:37 spiegel Exp $ 8 ;; $Id: vc.el,v 1.278 2000/10/05 22:55:17 monnier Exp $
9 9
10 ;; This file is part of GNU Emacs. 10 ;; This file is part of GNU Emacs.
11 11
12 ;; GNU Emacs is free software; you can redistribute it and/or modify 12 ;; GNU Emacs is free software; you can redistribute it and/or modify
13 ;; it under the terms of the GNU General Public License as published by 13 ;; it under the terms of the GNU General Public License as published by
1529 (if (or (not rel1) (string-equal rel1 "")) 1529 (if (or (not rel1) (string-equal rel1 ""))
1530 (setq rel1 (vc-workfile-version file))) 1530 (setq rel1 (vc-workfile-version file)))
1531 (if (string-equal rel2 "") 1531 (if (string-equal rel2 "")
1532 (setq rel2 nil)) 1532 (setq rel2 nil))
1533 (let ((file-rel1 (vc-version-backup-file file rel1)) 1533 (let ((file-rel1 (vc-version-backup-file file rel1))
1534 (file-rel2 (if (not rel2) 1534 (file-rel2 (if (not rel2)
1535 file 1535 file
1536 (vc-version-backup-file file rel2)))) 1536 (vc-version-backup-file file rel2))))
1537 (if (and file-rel1 file-rel2) 1537 (if (and file-rel1 file-rel2)
1538 (vc-do-command t 1 "diff" nil diff-switches file-rel1 file-rel2) 1538 (apply 'vc-do-command t 1 "diff" nil
1539 (append (if (listp diff-switches)
1540 diff-switches
1541 (list diff-switches))
1542 (list (file-relative-name file-rel1)
1543 (file-relative-name file-rel2))))
1539 (cd (file-name-directory file)) 1544 (cd (file-name-directory file))
1540 (vc-call diff file rel1 rel2)))) 1545 (vc-call diff file rel1 rel2))))
1541 (if (and (zerop (buffer-size)) 1546 (if (and (zerop (buffer-size))
1542 (not (get-buffer-process (current-buffer)))) 1547 (not (get-buffer-process (current-buffer))))
1543 (progn 1548 (progn