summaryrefslogtreecommitdiff
path: root/lisp/dired-x.el
diff options
context:
space:
mode:
authorGlenn Morris <rgm@gnu.org>2007-04-21 19:49:03 +0000
committerGlenn Morris <rgm@gnu.org>2007-04-21 19:49:03 +0000
commit00c6e161d681a9444c235f63f63695133f2e01ab (patch)
tree326a5e97aa287d7a9d0d88c8da6c1a958d8a8bcb /lisp/dired-x.el
parentef417216ffbb5091ee918335285a06cf64cc2b29 (diff)
downloademacs-00c6e161d681a9444c235f63f63695133f2e01ab.tar.gz
Johan Bockg� <bojohan at dd.chalmers.se>:
(dired-virtual-mode): Doc fix.
Diffstat (limited to 'lisp/dired-x.el')
-rw-r--r--lisp/dired-x.el13
1 files changed, 5 insertions, 8 deletions
diff --git a/lisp/dired-x.el b/lisp/dired-x.el
index f5e6250b475..eecb1dbb709 100644
--- a/lisp/dired-x.el
+++ b/lisp/dired-x.el
@@ -790,21 +790,18 @@ nil."
(revert-buffer)))
;; A zero-arg version of dired-virtual.
-;; You need my modified version of set-auto-mode for the
-;; `buffer-contents-mode-alist'.
-;; Or you use infer-mode.el and infer-mode-alist, same syntax.
(defun dired-virtual-mode ()
"Put current buffer into Virtual Dired mode (see `dired-virtual').
-Useful on `buffer-contents-mode-alist' (which see) with the regexp
+Useful on `magic-mode-alist' with the regexp
- \"^ \\(/[^ /]+\\)/?+:$\"
+ \"^ \\\\(/[^ /]+\\\\)+/?:$\"
to put saved dired buffers automatically into Virtual Dired mode.
-Also useful for `auto-mode-alist' (which see) like this:
+Also useful for `auto-mode-alist' like this:
- \(setq auto-mode-alist (cons '(\"[^/]\\.dired\\'\" . dired-virtual-mode)
- auto-mode-alist)\)"
+ (add-to-list 'auto-mode-alist
+ '(\"[^/]\\\\.dired\\\\'\" . dired-virtual-mode))"
(interactive)
(dired-virtual (dired-virtual-guess-dir)))