[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
bug#27940: Recursively delete dir34? (yes, no, all, quit)
From: |
Eli Zaretskii |
Subject: |
bug#27940: Recursively delete dir34? (yes, no, all, quit) |
Date: |
Fri, 04 Aug 2017 15:46:28 +0300 |
> From: Tino Calancha <tino.calancha@gmail.com>
> Cc: 27940@debbugs.gnu.org, jidanni@jidanni.org
> Date: Fri, 04 Aug 2017 18:29:41 +0900
>
> index 24759c6c9b..278acc2cf5 100644
> --- a/lisp/dired.el
> +++ b/lisp/dired.el
> @@ -2990,23 +2990,33 @@ dired-delete-file
>
> TRASH non-nil means to trash the file instead of deleting, provided
> `delete-by-moving-to-trash' (which see) is non-nil."
> - ;; This test is equivalent to
> - ;; (and (file-directory-p fn) (not (file-symlink-p fn)))
> - ;; but more efficient
> - (if (not (eq t (car (file-attributes file))))
> - (delete-file file trash)
> - (if (and recursive
> - (directory-files file t dired-re-no-dot) ; Not empty.
> - (or (eq recursive 'always)
> - (yes-or-no-p (format "Recursively %s %s? "
> - (if (and trash
> - delete-by-moving-to-trash)
> - "trash"
> - "delete")
> - (dired-make-relative file)))))
> - (if (eq recursive 'top) (setq recursive 'always)) ; Don't ask again.
> - (setq recursive nil))
> - (delete-directory file recursive trash)))
> + ;; This test is equivalent to
> + ;; (and (file-directory-p fn) (not (file-symlink-p fn)))
> + ;; but more efficient
> + (if (not (eq t (car (file-attributes file))))
> + (delete-file file trash)
> + (let* ((valid-answers (list "y" "n" "!" "q"))
Shouldn't the valid-answers be "yes" and "no", not "y" and "n", for
backward compatibility?
> + (completing-read (format "Recursively %s
> %s? [y, n, !, q] "
Maybe the "!" and "q" parts should be explained? Or maybe just use
"yes", "no", "all", and "quite", which are self-explanatory?
This warrants a NEWS entry, I think. I also wonder whether we should
describe this in the user manual, under "Dired Deletion".
Than ks.
- bug#27940: Recursively delete dir34? (yes, no, all, quit), 積丹尼 Dan Jacobson, 2017/08/03
- bug#27940: Recursively delete dir34? (yes, no, all, quit), Tino Calancha, 2017/08/04
- bug#27940: Recursively delete dir34? (yes, no, all, quit), Eli Zaretskii, 2017/08/04
- bug#27940: Recursively delete dir34? (yes, no, all, quit), Tino Calancha, 2017/08/04
- bug#27940: Recursively delete dir34? (yes, no, all, quit), Tino Calancha, 2017/08/04
- bug#27940: Recursively delete dir34? (yes, no, all, quit),
Eli Zaretskii <=
- bug#27940: Recursively delete dir34? (yes, no, all, quit), Tino Calancha, 2017/08/04
- bug#27940: Recursively delete dir34? (yes, no, all, quit), Eli Zaretskii, 2017/08/04
- bug#27940: Recursively delete dir34? (yes, no, all, quit), Drew Adams, 2017/08/04
- bug#27940: Recursively delete dir34? (yes, no, all, quit), Tino Calancha, 2017/08/04
- bug#27940: Recursively delete dir34? (yes, no, all, quit), Drew Adams, 2017/08/04
- bug#27940: Recursively delete dir34? (yes, no, all, quit), Tino Calancha, 2017/08/04
- bug#27940: Recursively delete dir34? (yes, no, all, quit), Tino Calancha, 2017/08/06
- Message not available
- bug#27940: Recursively delete dir34? (yes, no, all, quit), Tino Calancha, 2017/08/09