aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorGlenn Morris2014-03-22 16:56:19 -0700
committerGlenn Morris2014-03-22 16:56:19 -0700
commit5dbc3244732d3eb33809304f8d887f943cde780d (patch)
tree831f82b12d2bee6f1747b3f1468dd11ab13aba6f
parent00156f954984c1084180ca87832fcd32f05aa327 (diff)
downloademacs-5dbc3244732d3eb33809304f8d887f943cde780d.tar.gz
emacs-5dbc3244732d3eb33809304f8d887f943cde780d.zip
Make dired-read-regexp obsolete
It's not worth having such a trivial wrapper for read-regexp. * lisp/dired.el (dired-read-regexp): Make obsolete. (dired-mark-files-regexp, dired-mark-files-containing-regexp) (dired-flag-files-regexp): * lisp/dired-aux.el (dired-mark-read-regexp): * lisp/dired-x.el (dired-mark-unmarked-files): Use read-regexp directly.
-rw-r--r--lisp/ChangeLog6
-rw-r--r--lisp/dired-aux.el9
-rw-r--r--lisp/dired-x.el8
-rw-r--r--lisp/dired.el18
4 files changed, 26 insertions, 15 deletions
diff --git a/lisp/ChangeLog b/lisp/ChangeLog
index 8a5e9497f27..3e49f70f0b2 100644
--- a/lisp/ChangeLog
+++ b/lisp/ChangeLog
@@ -1,5 +1,11 @@
12014-03-22 Glenn Morris <rgm@gnu.org> 12014-03-22 Glenn Morris <rgm@gnu.org>
2 2
3 * dired.el (dired-read-regexp): Make obsolete.
4 (dired-mark-files-regexp, dired-mark-files-containing-regexp)
5 (dired-flag-files-regexp):
6 * dired-aux.el (dired-mark-read-regexp):
7 * dired-x.el (dired-mark-unmarked-files): Use read-regexp directly.
8
3 * startup.el (fancy-startup-text): 9 * startup.el (fancy-startup-text):
4 * help.el (describe-gnu-project): Visit online info about GNU project. 10 * help.el (describe-gnu-project): Visit online info about GNU project.
5 11
diff --git a/lisp/dired-aux.el b/lisp/dired-aux.el
index 1129dfd89f6..b59b7cecc34 100644
--- a/lisp/dired-aux.el
+++ b/lisp/dired-aux.el
@@ -1,7 +1,7 @@
1;;; dired-aux.el --- less commonly used parts of dired 1;;; dired-aux.el --- less commonly used parts of dired
2 2
3;; Copyright (C) 1985-1986, 1992, 1994, 1998, 2000-2014 Free Software 3;; Copyright (C) 1985-1986, 1992, 1994, 1998, 2000-2014
4;; Foundation, Inc. 4;; Free Software Foundation, Inc.
5 5
6;; Author: Sebastian Kremer <sk@thp.uni-koeln.de>. 6;; Author: Sebastian Kremer <sk@thp.uni-koeln.de>.
7;; Maintainer: emacs-devel@gnu.org 7;; Maintainer: emacs-devel@gnu.org
@@ -1921,8 +1921,9 @@ Type SPC or `y' to %s one match, DEL or `n' to skip to next,
1921 (arg 1921 (arg
1922 (if whole-name nil current-prefix-arg)) 1922 (if whole-name nil current-prefix-arg))
1923 (regexp 1923 (regexp
1924 (dired-read-regexp 1924 (read-regexp
1925 (concat (if whole-name "Abs. " "") operation " from (regexp): "))) 1925 (concat (if whole-name "Abs. " "") operation " from (regexp): ")
1926 nil 'dired-regexp-history))
1926 (newname 1927 (newname
1927 (read-string 1928 (read-string
1928 (concat (if whole-name "Abs. " "") operation " " regexp " to: ")))) 1929 (concat (if whole-name "Abs. " "") operation " " regexp " to: "))))
diff --git a/lisp/dired-x.el b/lisp/dired-x.el
index 947de7cd9f8..25c6f8b69af 100644
--- a/lisp/dired-x.el
+++ b/lisp/dired-x.el
@@ -1,7 +1,6 @@
1;;; dired-x.el --- extra Dired functionality -*- lexical-binding:t -*- 1;;; dired-x.el --- extra Dired functionality -*- lexical-binding:t -*-
2 2
3;; Copyright (C) 1993-1994, 1997, 2001-2014 Free Software Foundation, 3;; Copyright (C) 1993-1994, 1997, 2001-2014 Free Software Foundation, Inc.
4;; Inc.
5 4
6;; Author: Sebastian Kremer <sk@thp.uni-koeln.de> 5;; Author: Sebastian Kremer <sk@thp.uni-koeln.de>
7;; Lawrence R. Dodd <dodd@roebling.poly.edu> 6;; Lawrence R. Dodd <dodd@roebling.poly.edu>
@@ -556,8 +555,9 @@ interactively, prompt for REGEXP.
556With prefix argument, unflag all those files. 555With prefix argument, unflag all those files.
557Optional fourth argument LOCALP is as in `dired-get-filename'." 556Optional fourth argument LOCALP is as in `dired-get-filename'."
558 (interactive 557 (interactive
559 (list (dired-read-regexp 558 (list (read-regexp
560 "Mark unmarked files matching regexp (default all): ") 559 "Mark unmarked files matching regexp (default all): "
560 nil 'dired-regexp-history)
561 nil current-prefix-arg nil)) 561 nil current-prefix-arg nil))
562 (let ((dired-marker-char (if unflag-p ?\s dired-marker-char))) 562 (let ((dired-marker-char (if unflag-p ?\s dired-marker-char)))
563 (dired-mark-if 563 (dired-mark-if
diff --git a/lisp/dired.el b/lisp/dired.el
index f52036b8831..ee3ea689c4d 100644
--- a/lisp/dired.el
+++ b/lisp/dired.el
@@ -1,7 +1,7 @@
1;;; dired.el --- directory-browsing commands -*- lexical-binding: t -*- 1;;; dired.el --- directory-browsing commands -*- lexical-binding: t -*-
2 2
3;; Copyright (C) 1985-1986, 1992-1997, 2000-2014 Free Software 3;; Copyright (C) 1985-1986, 1992-1997, 2000-2014
4;; Foundation, Inc. 4;; Free Software Foundation, Inc.
5 5
6;; Author: Sebastian Kremer <sk@thp.uni-koeln.de> 6;; Author: Sebastian Kremer <sk@thp.uni-koeln.de>
7;; Maintainer: emacs-devel@gnu.org 7;; Maintainer: emacs-devel@gnu.org
@@ -3286,6 +3286,7 @@ As always, hidden subdirs are not affected."
3286 3286
3287(defun dired-read-regexp (prompt &optional default history) 3287(defun dired-read-regexp (prompt &optional default history)
3288 "Read a regexp using `read-regexp'." 3288 "Read a regexp using `read-regexp'."
3289 (declare (obsolete read-regexp "24.5"))
3289 (read-regexp prompt default (or history 'dired-regexp-history))) 3290 (read-regexp prompt default (or history 'dired-regexp-history)))
3290 3291
3291(defun dired-mark-files-regexp (regexp &optional marker-char) 3292(defun dired-mark-files-regexp (regexp &optional marker-char)
@@ -3296,8 +3297,9 @@ A prefix argument means to unmark them instead.
3296REGEXP is an Emacs regexp, not a shell wildcard. Thus, use `\\.o$' for 3297REGEXP is an Emacs regexp, not a shell wildcard. Thus, use `\\.o$' for
3297object files--just `.o' will mark more than you might think." 3298object files--just `.o' will mark more than you might think."
3298 (interactive 3299 (interactive
3299 (list (dired-read-regexp (concat (if current-prefix-arg "Unmark" "Mark") 3300 (list (read-regexp (concat (if current-prefix-arg "Unmark" "Mark")
3300 " files (regexp): ")) 3301 " files (regexp): ")
3302 nil 'dired-regexp-history)
3301 (if current-prefix-arg ?\040))) 3303 (if current-prefix-arg ?\040)))
3302 (let ((dired-marker-char (or marker-char dired-marker-char))) 3304 (let ((dired-marker-char (or marker-char dired-marker-char)))
3303 (dired-mark-if 3305 (dired-mark-if
@@ -3312,8 +3314,9 @@ object files--just `.o' will mark more than you might think."
3312A prefix argument means to unmark them instead. 3314A prefix argument means to unmark them instead.
3313`.' and `..' are never marked." 3315`.' and `..' are never marked."
3314 (interactive 3316 (interactive
3315 (list (dired-read-regexp (concat (if current-prefix-arg "Unmark" "Mark") 3317 (list (read-regexp (concat (if current-prefix-arg "Unmark" "Mark")
3316 " files containing (regexp): ")) 3318 " files containing (regexp): ")
3319 nil 'dired-regexp-history)
3317 (if current-prefix-arg ?\040))) 3320 (if current-prefix-arg ?\040)))
3318 (let ((dired-marker-char (or marker-char dired-marker-char))) 3321 (let ((dired-marker-char (or marker-char dired-marker-char)))
3319 (dired-mark-if 3322 (dired-mark-if
@@ -3343,7 +3346,8 @@ A prefix argument means to unmark them instead.
3343The match is against the non-directory part of the filename. Use `^' 3346The match is against the non-directory part of the filename. Use `^'
3344 and `$' to anchor matches. Exclude subdirs by hiding them. 3347 and `$' to anchor matches. Exclude subdirs by hiding them.
3345`.' and `..' are never flagged." 3348`.' and `..' are never flagged."
3346 (interactive (list (dired-read-regexp "Flag for deletion (regexp): "))) 3349 (interactive (list (read-regexp "Flag for deletion (regexp): "
3350 nil 'dired-regexp-history)))
3347 (dired-mark-files-regexp regexp dired-del-marker)) 3351 (dired-mark-files-regexp regexp dired-del-marker))
3348 3352
3349(defun dired-mark-symlinks (unflag-p) 3353(defun dired-mark-symlinks (unflag-p)