all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: Allen Li <vianchielfaura@gmail.com>
To: 29465@debbugs.gnu.org
Subject: bug#29465: 25.3; Confusing message for dired-do-shell-command substitution
Date: Sun, 26 Nov 2017 23:16:59 -0800	[thread overview]
Message-ID: <CAJr1M6f71vv2W090wPw8q_10wK=OwfgvMfM7DMiPn9G8oyY8AA@mail.gmail.com> (raw)

When you use * or ? in dired-do-shell-command without the intent for
Dired to replace it,  you are prompted with

  Confirm--do you mean to use `*' as a wildcard?

This message is confusing, because there are lots of ways for * to be
passed to the shell without globbing.  I am also more familiar with
the term globbing than wildcard, which makes it doubly confusing, for
example if I run

  find ? -name '*.txt'

I get the message:

  Confirm--do you mean to use `*' as a wildcard?

What the question is really asking is, should * be passed to the shell
directly, as whether or not it is interpreted as a glob is determined
by the shell and the quoting rules in question.

I think this confirmation message should be removed entirely.

1. The edge case that it is trying to protect against is not very common.
2. There is no reasonable behavior that the user could expect from
this edge case.
3. The documentation string clearly describes how * and ? are interpreted.
4. The confirmation message is not very informative and is possible misleading.
5. This confirmation message shows up every time an advanced user
wants to run any command containing * or ?, e.g. for find, grep, sed,
or many other tools.
6. The confirmation message is not even shown consistently.  For
example it is shown for

  find ? -name '*.txt'

but not for

  find * -name '*.txt'

Thus, it isn't even useful for protecting against some hypothetical
unwanted behavior.

In GNU Emacs 25.3.1 (x86_64-pc-linux-gnu, GTK+ Version 3.22.19)
 of 2017-09-16 built on juergen
Windowing system distributor 'The X.Org Foundation', version 11.0.11905000
Configured using:
 'configure --prefix=/usr --sysconfdir=/etc --libexecdir=/usr/lib
 --localstatedir=/var --with-x-toolkit=gtk3 --with-xft --with-modules
 'CFLAGS=-march=x86-64 -mtune=generic -O2 -pipe -fstack-protector-strong
 -fno-plt' CPPFLAGS=-D_FORTIFY_SOURCE=2
 LDFLAGS=-Wl,-O1,--sort-common,--as-needed,-z,relro,-z,now'





             reply	other threads:[~2017-11-27  7:16 UTC|newest]

Thread overview: 16+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-11-27  7:16 Allen Li [this message]
2017-11-27  7:34 ` bug#29465: 25.3; Confusing message for dired-do-shell-command substitution Allen Li
2017-11-27  9:07   ` Michael Heerdegen
2017-11-27 15:58 ` Eli Zaretskii
2017-11-28  3:50   ` Tino Calancha
2017-11-28  8:25     ` Allen Li
2017-11-28 16:26       ` Eli Zaretskii
2017-11-28 20:13         ` Allen Li
2017-11-29  4:20           ` Drew Adams
2017-12-01  8:36             ` Eli Zaretskii
2017-12-02  6:31               ` Allen Li
2017-12-02  7:32                 ` Tino Calancha
2017-12-02  8:22                   ` Allen Li
2022-03-22 16:48                     ` Lars Ingebrigtsen
2017-11-28 16:15     ` Eli Zaretskii
     [not found] <<CAJr1M6f71vv2W090wPw8q_10wK=OwfgvMfM7DMiPn9G8oyY8AA@mail.gmail.com>
     [not found] ` <<83vahv67eb.fsf@gnu.org>
     [not found]   ` <<87fu8zukmb.fsf@gmail.com>
     [not found]     ` <<CAJr1M6cuB0RPcUfzsGHCGt+8m6-KH58FX4NoD==APb7dksrs2g@mail.gmail.com>
     [not found]       ` <<83609u5pyr.fsf@gnu.org>
     [not found]         ` <<CAJr1M6cT578dcFT4Uvg29===-q=7omx5DG+JSTuqczjO3paGgg@mail.gmail.com>
     [not found]           ` <<29b407d1-e1f6-4676-a686-ccdf19af8bb4@default>
     [not found]             ` <<83mv323kvx.fsf@gnu.org>
2017-12-01 15:42               ` Drew Adams

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

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to='CAJr1M6f71vv2W090wPw8q_10wK=OwfgvMfM7DMiPn9G8oyY8AA@mail.gmail.com' \
    --to=vianchielfaura@gmail.com \
    --cc=29465@debbugs.gnu.org \
    /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 external index

	https://git.savannah.gnu.org/cgit/emacs.git
	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.