From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Eli Zaretskii Newsgroups: gmane.emacs.bugs Subject: bug#71935: split-string-and-unquote mishandles dired-listing-switches with ' Date: Fri, 05 Jul 2024 10:43:52 +0300 Message-ID: <86ed88707b.fsf@gnu.org> References: <86tth5tztt.fsf@mail.linkov.net> <86zfqx8tnn.fsf@gnu.org> <86a5ixqhd4.fsf@mail.linkov.net> <868qyh82is.fsf@gnu.org> <8634opowlq.fsf@mail.linkov.net> <8634op80r5.fsf@gnu.org> <86tth52dkl.fsf@mail.linkov.net> <86wmm16kuz.fsf@gnu.org> <86tth56kgw.fsf@gnu.org> <86sewoqqpk.fsf@mail.linkov.net> Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="26570"; mail-complaints-to="usenet@ciao.gmane.io" Cc: 71935@debbugs.gnu.org To: Juri Linkov Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Fri Jul 05 09:45:17 2024 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane-mx.org Original-Received: from lists.gnu.org ([209.51.188.17]) by ciao.gmane.io with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1sPdd6-0006hw-Qo for geb-bug-gnu-emacs@m.gmane-mx.org; Fri, 05 Jul 2024 09:45:16 +0200 Original-Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1sPdcu-0005iP-3v; Fri, 05 Jul 2024 03:45:04 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1sPdcp-0005hg-U9 for bug-gnu-emacs@gnu.org; Fri, 05 Jul 2024 03:44:59 -0400 Original-Received: from debbugs.gnu.org ([2001:470:142:5::43]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1sPdcp-0008Sx-K9 for bug-gnu-emacs@gnu.org; Fri, 05 Jul 2024 03:44:59 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1sPdcs-0000dP-D5 for bug-gnu-emacs@gnu.org; Fri, 05 Jul 2024 03:45:02 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Eli Zaretskii Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Fri, 05 Jul 2024 07:45:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 71935 X-GNU-PR-Package: emacs Original-Received: via spool by 71935-submit@debbugs.gnu.org id=B71935.17201654442337 (code B ref 71935); Fri, 05 Jul 2024 07:45:02 +0000 Original-Received: (at 71935) by debbugs.gnu.org; 5 Jul 2024 07:44:04 +0000 Original-Received: from localhost ([127.0.0.1]:43520 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1sPdbw-0000bc-EJ for submit@debbugs.gnu.org; Fri, 05 Jul 2024 03:44:04 -0400 Original-Received: from eggs.gnu.org ([209.51.188.92]:59170) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1sPdbu-0000as-FB for 71935@debbugs.gnu.org; Fri, 05 Jul 2024 03:44:03 -0400 Original-Received: from fencepost.gnu.org ([2001:470:142:3::e]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1sPdbl-0007SA-UJ; Fri, 05 Jul 2024 03:43:53 -0400 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnu.org; s=fencepost-gnu-org; h=MIME-version:References:Subject:In-Reply-To:To:From: Date; bh=rQWSOZL0X3069tqxz3LHN0a3QSAFjRys1xDQLSh89Ok=; b=JhjMxoDBdP2oTQ0FaSn1 WMHfc48GPpKUXUKQbM2UndlD/Hl4yd0CaEwxlst37aOkL1/wI98zk/A4laVwq8L4ogOsHd/Dw3dLb n10aiHAI6PNndY+Scpfn3QR7LudWl0f6OhpKiXciUx3lMshTfvoJ9qwhyKY6EPIAAPwINQ8eJf6Dh OBJ2PJfGePk5yZic2vEDbkorCoZOoXBC9TRegEzaEtIuYcy6WJ5QjIc2hh7CzI5FIQwXMvT3P76+h ZCmt9b7mR1liqbZW71JSrDx/FOISSkTt+U9h/t3d2UvGE+AblkWi9L4XmZpjH6CBKA9D65rwqrI7V u7NWbS+iNUkPPg==; In-Reply-To: <86sewoqqpk.fsf@mail.linkov.net> (message from Juri Linkov on Fri, 05 Jul 2024 09:48:39 +0300) X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list 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-mx.org@gnu.org Original-Sender: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Xref: news.gmane.io gmane.emacs.bugs:288412 Archived-At: > From: Juri Linkov > Cc: 71935@debbugs.gnu.org > Date: Fri, 05 Jul 2024 09:48:39 +0300 > > >> Thanks, that's what I had in mind. Please install on the emacs-30 > >> branch. > > > > On second thought: could there be options that include shell > > wildcards, which therefore should not be quoted? If so, perhaps > > instead of shell-quote-argument we should use > > shell-quote-wildcard-pattern? > > Indeed, there are ls switches that use wildcards, e.g. > ‘--hide=PATTERN’ and ‘--ignore=PATTERN’. But it seems > they are ignored anyway while using wildcards with 'ls -d', > so I can't test them. What I can confirm only is that with > > 1. (setopt dired-listing-switches "-al --block-size='1 --ignore=system*") > 2. C-x d /tmp/s* > > the switches are correctly quoted by 'shell-quote-wildcard-pattern': > > "ls -d --dired -N -al --block-size=\\'1 --ignore=system* -- s*" Thanks. So I think this is a better solution for this tricky problem.