changeset 77369:0e2f72a2fc13

Johan Bockg? <bojohan at dd.chalmers.se>: (dired-virtual-mode): Doc fix.
author Glenn Morris <rgm@gnu.org>
date Sat, 21 Apr 2007 19:49:03 +0000
parents 84341be2fe3b
children 2c0170938587
files lisp/dired-x.el
diffstat 1 files changed, 5 insertions(+), 8 deletions(-) [+]
line wrap: on
line diff
--- a/lisp/dired-x.el	Sat Apr 21 19:48:15 2007 +0000
+++ b/lisp/dired-x.el	Sat Apr 21 19:49:03 2007 +0000
@@ -790,21 +790,18 @@
     (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)))