From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!.POSTED.blaine.gmane.org!not-for-mail From: Juri Linkov Newsgroups: gmane.emacs.bugs Subject: bug#35564: [PATCH v4] Tweak dired warning about "wildcard" characters Date: Fri, 09 Aug 2019 21:03:49 +0300 Organization: LINKOV.NET Message-ID: <87wofm8bcq.fsf@mail.linkov.net> References: <87zho2cd4f.fsf@gmail.com> <87wohvf22u.fsf@gmail.com> <87h88cvpkj.fsf_-_@gmail.com> <87imsinbmr.fsf_-_@gmail.com> <87y313z3tp.fsf@gmail.com> <83wog3lo5c.fsf@gnu.org> <87wog3pewu.fsf@gmail.com> <87v9vndsnj.fsf@web.de> <87imrl4ixr.fsf@web.de> <87r2688y1l.fsf@gmail.com> <87sgqkjfxv.fsf@web.de> <87tvas2b5o.fsf@gmail.com> <87d0hffjda.fsf@mail.linkov.net> <87k1bmfr1b.fsf@gmail.com> Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Injection-Info: blaine.gmane.org; posting-host="blaine.gmane.org:195.159.176.226"; logging-data="43797"; mail-complaints-to="usenet@blaine.gmane.org" User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/27.0.50 (x86_64-pc-linux-gnu) Cc: Michael Heerdegen , 35564@debbugs.gnu.org, monnier@iro.umontreal.ca, npostavs@gmail.com To: =?UTF-8?Q?K=C3=A9vin?= Le Gouguec Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Fri Aug 09 20:11:16 2019 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([209.51.188.17]) by blaine.gmane.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.89) (envelope-from ) id 1hw9MC-000BF2-CW for geb-bug-gnu-emacs@m.gmane.org; Fri, 09 Aug 2019 20:11:16 +0200 Original-Received: from localhost ([::1]:33312 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.86_2) (envelope-from ) id 1hw9MB-0000su-EG for geb-bug-gnu-emacs@m.gmane.org; Fri, 09 Aug 2019 14:11:15 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:45954) by lists.gnu.org with esmtp (Exim 4.86_2) (envelope-from ) id 1hw9Lz-0000rU-6r for bug-gnu-emacs@gnu.org; Fri, 09 Aug 2019 14:11:04 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1hw9Ly-0003Ex-1h for bug-gnu-emacs@gnu.org; Fri, 09 Aug 2019 14:11:03 -0400 Original-Received: from debbugs.gnu.org ([209.51.188.43]:34422) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1hw9Lx-0003Em-Uy for bug-gnu-emacs@gnu.org; Fri, 09 Aug 2019 14:11:01 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1hw9Lx-0007xU-O1 for bug-gnu-emacs@gnu.org; Fri, 09 Aug 2019 14:11:01 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Juri Linkov Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Fri, 09 Aug 2019 18:11:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 35564 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: patch Original-Received: via spool by 35564-submit@debbugs.gnu.org id=B35564.156537422930536 (code B ref 35564); Fri, 09 Aug 2019 18:11:01 +0000 Original-Received: (at 35564) by debbugs.gnu.org; 9 Aug 2019 18:10:29 +0000 Original-Received: from localhost ([127.0.0.1]:43240 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1hw9LR-0007wR-68 for submit@debbugs.gnu.org; Fri, 09 Aug 2019 14:10:29 -0400 Original-Received: from anteater.elm.relay.mailchannels.net ([23.83.212.3]:35547) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1hw9LO-0007wC-3A for 35564@debbugs.gnu.org; Fri, 09 Aug 2019 14:10:26 -0400 X-Sender-Id: dreamhost|x-authsender|jurta@jurta.org Original-Received: from relay.mailchannels.net (localhost [127.0.0.1]) by relay.mailchannels.net (Postfix) with ESMTP id D90DF1A2D58; Fri, 9 Aug 2019 18:10:24 +0000 (UTC) Original-Received: from pdx1-sub0-mail-a11.g.dreamhost.com (100-96-4-86.trex.outbound.svc.cluster.local [100.96.4.86]) (Authenticated sender: dreamhost) by relay.mailchannels.net (Postfix) with ESMTPA id 2DC9D1A2D09; Fri, 9 Aug 2019 18:10:22 +0000 (UTC) X-Sender-Id: dreamhost|x-authsender|jurta@jurta.org Original-Received: from pdx1-sub0-mail-a11.g.dreamhost.com ([TEMPUNAVAIL]. [64.90.62.162]) (using TLSv1.2 with cipher DHE-RSA-AES256-GCM-SHA384) by 0.0.0.0:2500 (trex/5.17.5); Fri, 09 Aug 2019 18:10:24 +0000 X-MC-Relay: Neutral X-MailChannels-SenderId: dreamhost|x-authsender|jurta@jurta.org X-MailChannels-Auth-Id: dreamhost X-Cooing-Callous: 1b4fede61a17664c_1565374222549_2203405489 X-MC-Loop-Signature: 1565374222549:4231441895 X-MC-Ingress-Time: 1565374222549 Original-Received: from pdx1-sub0-mail-a11.g.dreamhost.com (localhost [127.0.0.1]) by pdx1-sub0-mail-a11.g.dreamhost.com (Postfix) with ESMTP id DEB27835BD; Fri, 9 Aug 2019 11:10:18 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha1; c=relaxed; d=linkov.net; h=from:to:cc :subject:references:date:in-reply-to:message-id:mime-version :content-type:content-transfer-encoding; s=linkov.net; bh=ww+Lbh 9ZNLQNCygbdu8Dc/1+3Og=; b=uo5UyKjDYHe4ExQeE9iZMDGEFEMglIt7vO+Vac 8eBXxeTWfJm9mvWHFhaIjwBPSOnuw+9QvKeYFJgKDciVQiPmD+NihXfZ64TZA1FO dORLXU3KyUwNQ0JLQs4F0eGV8i8jiCZRRK31R53H07V1eQ3mjFetZXpYNFkFEhCR jXOog= Original-Received: from mail.jurta.org (m91-129-103-91.cust.tele2.ee [91.129.103.91]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) (Authenticated sender: jurta@jurta.org) by pdx1-sub0-mail-a11.g.dreamhost.com (Postfix) with ESMTPSA id E887183527; Fri, 9 Aug 2019 11:10:13 -0700 (PDT) X-DH-BACKEND: pdx1-sub0-mail-a11 In-Reply-To: <87k1bmfr1b.fsf@gmail.com> ("=?UTF-8?Q?K=C3=A9vin?= Le Gouguec"'s message of "Fri, 09 Aug 2019 14:43:12 +0200") X-VR-OUT-STATUS: OK X-VR-OUT-SCORE: -100 X-VR-OUT-SPAMCAUSE: gggruggvucftvghtrhhoucdtuddrgeduvddruddujedguddvudcutefuodetggdotefrodftvfcurfhrohhfihhlvgemucggtfgfnhhsuhgsshgtrhhisggvpdfftffgtefojffquffvnecuuegrihhlohhuthemuceftddtnecusecvtfgvtghiphhivghnthhsucdlqddutddtmdenucfjughrpefhvffuohhfffgjkfgfgggtgfesthekredttderjeenucfhrhhomheplfhurhhiucfnihhnkhhovhcuoehjuhhriheslhhinhhkohhvrdhnvghtqeenucfkphepledurdduvdelrddutdefrdeludenucfrrghrrghmpehmohguvgepshhmthhppdhhvghlohepmhgrihhlrdhjuhhrthgrrdhorhhgpdhinhgvthepledurdduvdelrddutdefrdeluddprhgvthhurhhnqdhprghthheplfhurhhiucfnihhnkhhovhcuoehjuhhriheslhhinhhkohhvrdhnvghtqedpmhgrihhlfhhrohhmpehjuhhriheslhhinhhkohhvrdhnvghtpdhnrhgtphhtthhopehkvghvihhnrdhlvghgohhughhuvggtsehgmhgrihhlrdgtohhmnecuvehluhhsthgvrhfuihiivgeptd X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Received-From: 209.51.188.43 X-BeenThere: bug-gnu-emacs@gnu.org List-Id: "Bug reports for GNU Emacs, the Swiss army knife of text editors" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Original-Sender: "bug-gnu-emacs" Xref: news.gmane.org gmane.emacs.bugs:164813 Archived-At: >> 2. The current question is too ambiguous: >> >> Confirm--do you mean to use =E2=80=98?=E2=80=99 as a wildcard? (y or= n) >> >> A wildcard can mean both dired substitution and shell substitution. >> A better question should use the same terms as documented in the >> docstring of `dired-do-shell-command', i.e. "marked files", "file list= ". >> So a better question would be: >> >> Confirm--do you mean to substitute =E2=80=98?=E2=80=99 with marked f= iles? (y or n) >> >> Or something similar that makes clear that substitution applies >> to dired files, not files matched by shell. > > Mmm, I think that the current prompt *does* use the same terms as > documented in the docstring: it simply mistakenly assumes that if '?' > and '*' are not "isolated", the shell will unconditionally process them > as wildcards. It is a heuristic that fails to consider that '?' and '*= ' > may be quoted or escaped. Do you mean this case: despite that the docstring of `dired-do-shell-command' mentions "a shell wildcard", typing on a file: ! cat '*' and confirming with `y': Confirm--do you mean to use =E2=80=98*=E2=80=99 as a wildcard? (y or n)= y still doesn't use * as "a shell wildcard". Then I agree. >> As was already discussed in this thread, using (:inherit '(warning und= erline)) >> will solve this problem and improve accessibility. So there will be >> no need in multi-line prompt when using underline face attribute. > > Mmm. I went to a TTY to check how (:inherit '(underline)) looks. Sinc= e > (display-supports-face-attributes-p '(:underline t)) is nil there, the > "underline" face is defined as (:weight bold), which merely makes the > foreground color brighter. So (:inherit '(warning underline)) amounts > to just (:inherit '(warning)). > > Perhaps (display-supports-face-attributes-p '(:underline t)) can be use= d > to decide whether we need to add ^ markers. You can check all possible face attributes to find the one available on tty: underline, weight: bold, inverse-video, ...