|
From: | Juri Linkov |
Subject: | bug#13152: 24.2.90; [REGRESSION] dired-get-marked-files changed |
Date: | Thu, 13 Dec 2012 01:11:39 +0200 |
User-agent: | Gnus/5.13 (Gnus v5.13) Emacs/24.3.50 (x86_64-pc-linux-gnu) |
>> I see no problems with this. > > See dired-guess-shell-alist-user, COMMAND can be an expression which is > eval'd in different contexts (buffers) and that is a problem. Actually I meant there is no bug because the documentation of dired-guess-shell-alist-user says nothing about the current buffer. But indeed you have a problem when trying to do undocumented things. Without changing the source code you can reuse the existing variable `files' dynamically bound in `dired-guess-shell-command' like: (progn (require 'dired-x) (setq dired-guess-shell-alist-user '(("." (progn (message "%S" files) (let (dired-guess-shell-alist-user) (dired-guess-default files))))))) This is bad practice but acceptable for ~/.emacs. Regarding changing the current buffer in `dired-mark-pop-up' where an expression is evaluated, I have doubts because it might broke code that relies on the fact that the selected window and the current buffer should be " *Marked Files*" as it was in all older versions.
[Prev in Thread] | Current Thread | [Next in Thread] |