diff options
| author | Glenn Morris | 2014-10-20 18:39:30 -0400 |
|---|---|---|
| committer | Stefan Monnier | 2014-10-20 18:39:30 -0400 |
| commit | 3ac4e4c0eb19cecf7adce4ad6ffe60f70ad8a72d (patch) | |
| tree | 9498c919d402628b53e5d630c4afebc7a66ed816 | |
| parent | c9f7e33c60b95981367187d0419b50a8d4024ff4 (diff) | |
| download | emacs-3ac4e4c0eb19cecf7adce4ad6ffe60f70ad8a72d.tar.gz emacs-3ac4e4c0eb19cecf7adce4ad6ffe60f70ad8a72d.zip | |
* lisp/dired.el (dired-read-regexp): Make obsolete. [Backport]
(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/ChangeLog | 8 | ||||
| -rw-r--r-- | lisp/dired-aux.el | 9 | ||||
| -rw-r--r-- | lisp/dired-x.el | 8 | ||||
| -rw-r--r-- | lisp/dired.el | 18 |
4 files changed, 28 insertions, 15 deletions
diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 9e1ffa7ba20..7fabbf14038 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog | |||
| @@ -1,3 +1,11 @@ | |||
| 1 | 2014-10-20 Glenn Morris <rgm@gnu.org> | ||
| 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 | |||
| 1 | 2014-10-20 Stefan Monnier <monnier@iro.umontreal.ca> | 9 | 2014-10-20 Stefan Monnier <monnier@iro.umontreal.ca> |
| 2 | 10 | ||
| 3 | * progmodes/python.el (inferior-python-mode): Use add-hook. | 11 | * progmodes/python.el (inferior-python-mode): Use add-hook. |
diff --git a/lisp/dired-aux.el b/lisp/dired-aux.el index b1d5f4e53b0..432d2307725 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. | |||
| 556 | With prefix argument, unflag all those files. | 555 | With prefix argument, unflag all those files. |
| 557 | Optional fourth argument LOCALP is as in `dired-get-filename'." | 556 | Optional 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 60f8c1e9dfc..98d3032637b 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 |
| @@ -3302,6 +3302,7 @@ As always, hidden subdirs are not affected." | |||
| 3302 | 3302 | ||
| 3303 | (defun dired-read-regexp (prompt &optional default history) | 3303 | (defun dired-read-regexp (prompt &optional default history) |
| 3304 | "Read a regexp using `read-regexp'." | 3304 | "Read a regexp using `read-regexp'." |
| 3305 | (declare (obsolete read-regexp "24.5")) | ||
| 3305 | (read-regexp prompt default (or history 'dired-regexp-history))) | 3306 | (read-regexp prompt default (or history 'dired-regexp-history))) |
| 3306 | 3307 | ||
| 3307 | (defun dired-mark-files-regexp (regexp &optional marker-char) | 3308 | (defun dired-mark-files-regexp (regexp &optional marker-char) |
| @@ -3312,8 +3313,9 @@ A prefix argument means to unmark them instead. | |||
| 3312 | REGEXP is an Emacs regexp, not a shell wildcard. Thus, use `\\.o$' for | 3313 | REGEXP is an Emacs regexp, not a shell wildcard. Thus, use `\\.o$' for |
| 3313 | object files--just `.o' will mark more than you might think." | 3314 | object files--just `.o' will mark more than you might think." |
| 3314 | (interactive | 3315 | (interactive |
| 3315 | (list (dired-read-regexp (concat (if current-prefix-arg "Unmark" "Mark") | 3316 | (list (read-regexp (concat (if current-prefix-arg "Unmark" "Mark") |
| 3316 | " files (regexp): ")) | 3317 | " files (regexp): ") |
| 3318 | nil 'dired-regexp-history) | ||
| 3317 | (if current-prefix-arg ?\040))) | 3319 | (if current-prefix-arg ?\040))) |
| 3318 | (let ((dired-marker-char (or marker-char dired-marker-char))) | 3320 | (let ((dired-marker-char (or marker-char dired-marker-char))) |
| 3319 | (dired-mark-if | 3321 | (dired-mark-if |
| @@ -3328,8 +3330,9 @@ object files--just `.o' will mark more than you might think." | |||
| 3328 | A prefix argument means to unmark them instead. | 3330 | A prefix argument means to unmark them instead. |
| 3329 | `.' and `..' are never marked." | 3331 | `.' and `..' are never marked." |
| 3330 | (interactive | 3332 | (interactive |
| 3331 | (list (dired-read-regexp (concat (if current-prefix-arg "Unmark" "Mark") | 3333 | (list (read-regexp (concat (if current-prefix-arg "Unmark" "Mark") |
| 3332 | " files containing (regexp): ")) | 3334 | " files containing (regexp): ") |
| 3335 | nil 'dired-regexp-history) | ||
| 3333 | (if current-prefix-arg ?\040))) | 3336 | (if current-prefix-arg ?\040))) |
| 3334 | (let ((dired-marker-char (or marker-char dired-marker-char))) | 3337 | (let ((dired-marker-char (or marker-char dired-marker-char))) |
| 3335 | (dired-mark-if | 3338 | (dired-mark-if |
| @@ -3359,7 +3362,8 @@ A prefix argument means to unmark them instead. | |||
| 3359 | The match is against the non-directory part of the filename. Use `^' | 3362 | The match is against the non-directory part of the filename. Use `^' |
| 3360 | and `$' to anchor matches. Exclude subdirs by hiding them. | 3363 | and `$' to anchor matches. Exclude subdirs by hiding them. |
| 3361 | `.' and `..' are never flagged." | 3364 | `.' and `..' are never flagged." |
| 3362 | (interactive (list (dired-read-regexp "Flag for deletion (regexp): "))) | 3365 | (interactive (list (read-regexp "Flag for deletion (regexp): " |
| 3366 | nil 'dired-regexp-history))) | ||
| 3363 | (dired-mark-files-regexp regexp dired-del-marker)) | 3367 | (dired-mark-files-regexp regexp dired-del-marker)) |
| 3364 | 3368 | ||
| 3365 | (defun dired-mark-symlinks (unflag-p) | 3369 | (defun dired-mark-symlinks (unflag-p) |