diff options
| author | Richard M. Stallman | 1995-11-13 20:24:46 +0000 |
|---|---|---|
| committer | Richard M. Stallman | 1995-11-13 20:24:46 +0000 |
| commit | 221cc4f4dc643b9196b8258fe0c30fb2a23d47e5 (patch) | |
| tree | 94b0a23bb1ecac66ddaf8ea4dc376796d67cdaa8 | |
| parent | bb441948ca0659a93a34c4d6712a339259da3397 (diff) | |
| download | emacs-221cc4f4dc643b9196b8258fe0c30fb2a23d47e5.tar.gz emacs-221cc4f4dc643b9196b8258fe0c30fb2a23d47e5.zip | |
(vc-directory): Require dired.
(vc-revert-buffer): Ignore vc-suppress-confirm.
| -rw-r--r-- | lisp/vc.el | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/lisp/vc.el b/lisp/vc.el index d550dd4a277..b81b2990502 100644 --- a/lisp/vc.el +++ b/lisp/vc.el | |||
| @@ -1337,6 +1337,7 @@ on a buffer attached to the file named in the current Dired buffer line." | |||
| 1337 | Normally it creates a Dired buffer that lists only the locked files | 1337 | Normally it creates a Dired buffer that lists only the locked files |
| 1338 | in all these directories. With a prefix argument, it lists all files." | 1338 | in all these directories. With a prefix argument, it lists all files." |
| 1339 | (interactive "DDired under VC (directory): \nP") | 1339 | (interactive "DDired under VC (directory): \nP") |
| 1340 | (require 'dired) | ||
| 1340 | (setq dirname (expand-file-name dirname)) | 1341 | (setq dirname (expand-file-name dirname)) |
| 1341 | ;; force a trailing slash | 1342 | ;; force a trailing slash |
| 1342 | (if (not (eq (elt dirname (1- (length dirname))) ?/)) | 1343 | (if (not (eq (elt dirname (1- (length dirname))) ?/)) |
| @@ -1577,9 +1578,10 @@ the file on the branch you are editing." | |||
| 1577 | (while vc-parent-buffer | 1578 | (while vc-parent-buffer |
| 1578 | (pop-to-buffer vc-parent-buffer)) | 1579 | (pop-to-buffer vc-parent-buffer)) |
| 1579 | (let ((file buffer-file-name) | 1580 | (let ((file buffer-file-name) |
| 1581 | ;; This operation should always ask for confirmation. | ||
| 1582 | (vc-suppress-confirm nil) | ||
| 1580 | (obuf (current-buffer)) (changed (vc-diff nil t))) | 1583 | (obuf (current-buffer)) (changed (vc-diff nil t))) |
| 1581 | (if (and changed (or vc-suppress-confirm | 1584 | (if (and changed (not (yes-or-no-p "Discard changes? "))) |
| 1582 | (not (yes-or-no-p "Discard changes? ")))) | ||
| 1583 | (progn | 1585 | (progn |
| 1584 | (if (and (window-dedicated-p (selected-window)) | 1586 | (if (and (window-dedicated-p (selected-window)) |
| 1585 | (one-window-p t 'selected-frame)) | 1587 | (one-window-p t 'selected-frame)) |