diff options
| author | Richard M. Stallman | 1995-07-18 20:55:46 +0000 |
|---|---|---|
| committer | Richard M. Stallman | 1995-07-18 20:55:46 +0000 |
| commit | 45fc7cc3c58ab3748b27ad9cc796560c64de4bec (patch) | |
| tree | 3c87c8143c70026ff589266d607b90c62c375059 | |
| parent | 6aa1372974aa293dc103acaf046c82d1b0e6665e (diff) | |
| download | emacs-45fc7cc3c58ab3748b27ad9cc796560c64de4bec.tar.gz emacs-45fc7cc3c58ab3748b27ad9cc796560c64de4bec.zip | |
(vc-mode-line, vc-find-file-hook): Moved the test for
version-controlled symbolic link from the former to the latter.
| -rw-r--r-- | lisp/vc-hooks.el | 15 |
1 files changed, 7 insertions, 8 deletions
diff --git a/lisp/vc-hooks.el b/lisp/vc-hooks.el index f4153a00eed..88ef2dbe1f5 100644 --- a/lisp/vc-hooks.el +++ b/lisp/vc-hooks.el | |||
| @@ -746,13 +746,6 @@ control system name." | |||
| 746 | (zerop (user-uid)) | 746 | (zerop (user-uid)) |
| 747 | (not (equal (user-login-name) (vc-locking-user file))) | 747 | (not (equal (user-login-name) (vc-locking-user file))) |
| 748 | (setq buffer-read-only t)) | 748 | (setq buffer-read-only t)) |
| 749 | (and (null vc-type) | ||
| 750 | (file-symlink-p file) | ||
| 751 | (let ((link-type (vc-backend (file-symlink-p file)))) | ||
| 752 | (if link-type | ||
| 753 | (message | ||
| 754 | "Warning: symbolic link to %s-controlled source file" | ||
| 755 | link-type)))) | ||
| 756 | (force-mode-line-update) | 749 | (force-mode-line-update) |
| 757 | ;;(set-buffer-modified-p (buffer-modified-p)) ;;use this if Emacs 18 | 750 | ;;(set-buffer-modified-p (buffer-modified-p)) ;;use this if Emacs 18 |
| 758 | vc-type)) | 751 | vc-type)) |
| @@ -800,7 +793,13 @@ control system name." | |||
| 800 | ;; Use this variable, not make-backup-files, | 793 | ;; Use this variable, not make-backup-files, |
| 801 | ;; because this is for things that depend on the file name. | 794 | ;; because this is for things that depend on the file name. |
| 802 | (make-local-variable 'backup-inhibited) | 795 | (make-local-variable 'backup-inhibited) |
| 803 | (setq backup-inhibited t)))))))) | 796 | (setq backup-inhibited t)))) |
| 797 | ((let* ((link (file-symlink-p buffer-file-name)) | ||
| 798 | (link-type (and link (vc-backend link)))) | ||
| 799 | (if link-type | ||
| 800 | (message | ||
| 801 | "Warning: symbolic link to %s-controlled source file" | ||
| 802 | link-type)))))))) | ||
| 804 | 803 | ||
| 805 | (add-hook 'find-file-hooks 'vc-find-file-hook) | 804 | (add-hook 'find-file-hooks 'vc-find-file-hook) |
| 806 | 805 | ||