From: Juri Linkov <juri@jurta.org>
To: Drew Adams <drew.adams@oracle.com>
Cc: 2414@emacsbugs.donarmstrong.com
Subject: bug#2414: 23.0.90; use dired-guess-default too for minibuffer-default-add-shell-commands
Date: Sun, 22 Feb 2009 23:54:10 +0200 [thread overview]
Message-ID: <87r61qf8ph.fsf@jurta.org> (raw)
In-Reply-To: <000601c99396$05d396a0$0200a8c0@us.oracle.com> (Drew Adams's message of "Fri, 20 Feb 2009 12:01:29 -0800")
> Enhancement request:
>
> `minibuffer-default-add-shell-commands' should add to the minibuffer
> defaults list not only the commands determined by MIME type (which it
> does now, using `mailcap-file-default-commands'), but also the
> commands determined by `dired-guess-default'.
>
> `dired-guess-default' is defined in dired-x.el, but it has nothing to
> do with Dired, AFAICT, so there is no reason that it should not be
> available (and used) generally.
>
> And variables `dired-guess-shell-alist-user' and
> `dired-guess-shell-alist-default' should also be factored out of
> dired-x.el. They too are not Dired-related, AFAICT.
Instead of generalizing `dired-guess-shell-alist-default',
I'd rather create a similar user-defined list of commands
to override default MIME commands in `mailcap-mime-data'
(using something like `mailcap-add').
> Note, BTW, that dired-x.el already uses `minibuffer-default-add-shell-commands'
> in `dired-smart-shell-command' (in dired-x.el). It makes no
> sense that only the MIME types be used to come up with defaults, and
> not also `dired-guess-default', in the very library that defines
> `dired-guess-default'!
Thanks for the pointer. After moving code with
`minibuffer-default-add-shell-commands' from `shell-command'
to `read-shell-command' on 2008-07-31 I forgot to change
`dired-smart-shell-command' the same way. Fixed now.
> My guess is that someone just updated `dired-smart-shell-command' for
> Emacs 23 mechanically, without thinking about the commands provided
> by `dired-guess-default'. IOW, it was a mechanical substitution of
> the same diff that was used to update `read-shell-command'.
`dired-smart-shell-command' is unrelated to `dired-guess-default'
with its alists. `dired-smart-shell-command' is bound to `M-!'
and according to its docstring it should work like `shell-command'.
Moreover, currently `M-!' is the only way to use MIME commands from
`mailcap-file-default-commands' when dired-x is loaded!
--
Juri Linkov
http://www.jurta.org/emacs/
next prev parent reply other threads:[~2009-02-22 21:54 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2009-02-20 20:01 bug#2414: 23.0.90; use dired-guess-default too for minibuffer-default-add-shell-commands Drew Adams
2009-02-22 21:54 ` Juri Linkov [this message]
2009-02-22 23:04 ` Drew Adams
2009-02-22 23:37 ` Juri Linkov
2009-02-23 0:25 ` Drew Adams
2021-12-04 21:27 ` Lars Ingebrigtsen
2021-12-05 9:25 ` Juri Linkov
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
List information: https://www.gnu.org/software/emacs/
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=87r61qf8ph.fsf@jurta.org \
--to=juri@jurta.org \
--cc=2414@emacsbugs.donarmstrong.com \
--cc=drew.adams@oracle.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
Code repositories for project(s) associated with this public inbox
https://git.savannah.gnu.org/cgit/emacs.git
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).