From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Juri Linkov Newsgroups: gmane.emacs.bugs 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 Organization: JURTA Message-ID: <87r61qf8ph.fsf@jurta.org> References: <000601c99396$05d396a0$0200a8c0@us.oracle.com> Reply-To: Juri Linkov , 2414@emacsbugs.donarmstrong.com NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Trace: ger.gmane.org 1235341449 5332 80.91.229.12 (22 Feb 2009 22:24:09 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Sun, 22 Feb 2009 22:24:09 +0000 (UTC) Cc: 2414@emacsbugs.donarmstrong.com To: Drew Adams Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Sun Feb 22 23:25:25 2009 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([199.232.76.165]) by lo.gmane.org with esmtp (Exim 4.50) id 1LbMlE-0006kw-5D for geb-bug-gnu-emacs@m.gmane.org; Sun, 22 Feb 2009 23:25:20 +0100 Original-Received: from localhost ([127.0.0.1]:39026 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1LbMjt-0005qf-MZ for geb-bug-gnu-emacs@m.gmane.org; Sun, 22 Feb 2009 17:23:57 -0500 Original-Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1LbMjd-0005a5-H0 for bug-gnu-emacs@gnu.org; Sun, 22 Feb 2009 17:23:41 -0500 Original-Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1LbMjb-0005Wn-LM for bug-gnu-emacs@gnu.org; Sun, 22 Feb 2009 17:23:41 -0500 Original-Received: from [199.232.76.173] (port=48947 helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1LbMjb-0005WW-HM for bug-gnu-emacs@gnu.org; Sun, 22 Feb 2009 17:23:39 -0500 Original-Received: from rzlab.ucr.edu ([138.23.92.77]:49597) by monty-python.gnu.org with esmtps (TLS-1.0:DHE_RSA_AES_256_CBC_SHA1:32) (Exim 4.60) (envelope-from ) id 1LbMjb-0005Ft-29 for bug-gnu-emacs@gnu.org; Sun, 22 Feb 2009 17:23:39 -0500 Original-Received: from rzlab.ucr.edu (rzlab.ucr.edu [127.0.0.1]) by rzlab.ucr.edu (8.13.8/8.13.8/Debian-3) with ESMTP id n1MMNa9P018950; Sun, 22 Feb 2009 14:23:37 -0800 Original-Received: (from debbugs@localhost) by rzlab.ucr.edu (8.13.8/8.13.8/Submit) id n1MM59lf014520; Sun, 22 Feb 2009 14:05:09 -0800 X-Loop: owner@emacsbugs.donarmstrong.com Resent-From: Juri Linkov Resent-To: bug-submit-list@donarmstrong.com Resent-CC: Emacs Bugs Resent-Date: Sun, 22 Feb 2009 22:05:09 +0000 Resent-Message-ID: Resent-Sender: owner@emacsbugs.donarmstrong.com X-Emacs-PR-Message: followup 2414 X-Emacs-PR-Package: emacs X-Emacs-PR-Keywords: Original-Received: via spool by 2414-submit@emacsbugs.donarmstrong.com id=B2414.123533976812187 (code B ref 2414); Sun, 22 Feb 2009 22:05:09 +0000 Original-Received: (at 2414) by emacsbugs.donarmstrong.com; 22 Feb 2009 21:56:08 +0000 X-Spam-Bayes: score:0.5 Bayes not run. spammytokens:Tokens not available. hammytokens:Tokens not available. Original-Received: from relay03.kiev.sovam.com (relay03.kiev.sovam.com [62.64.120.201]) by rzlab.ucr.edu (8.13.8/8.13.8/Debian-3) with ESMTP id n1MLu4fo012181 for <2414@emacsbugs.donarmstrong.com>; Sun, 22 Feb 2009 13:56:05 -0800 Original-Received: from [83.170.232.243] (helo=smtp.svitonline.com) by relay03.kiev.sovam.com with esmtp (Exim 4.69) (envelope-from ) id 1LbMIt-000B1a-DB; Sun, 22 Feb 2009 23:56:03 +0200 In-Reply-To: <000601c99396$05d396a0$0200a8c0@us.oracle.com> (Drew Adams's message of "Fri, 20 Feb 2009 12:01:29 -0800") User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/23.0.90 (x86_64-pc-linux-gnu) X-Scanner-Signature: 7155bbd8d023de41950ebecbe4708355 X-DrWeb-checked: yes X-detected-operating-system: by monty-python.gnu.org: GNU/Linux 2.6 (newer, 3) Resent-Date: Sun, 22 Feb 2009 17:23:41 -0500 X-BeenThere: bug-gnu-emacs@gnu.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "Bug reports for GNU Emacs, the Swiss army knife of text editors" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Original-Sender: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Errors-To: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.bugs:25605 Archived-At: > 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/