From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.ciao.gmane.io!not-for-mail From: "R. Diez" Newsgroups: gmane.emacs.help Subject: shell-quote-argument escapes '=' Date: Fri, 24 Apr 2020 12:35:51 +0000 (UTC) Message-ID: <1235716199.473564.1587731751300@mail.yahoo.com> References: <1235716199.473564.1587731751300.ref@mail.yahoo.com> Mime-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable Injection-Info: ciao.gmane.io; posting-host="ciao.gmane.io:159.69.161.202"; logging-data="94238"; mail-complaints-to="usenet@ciao.gmane.io" To: "help-gnu-emacs@gnu.org" Original-X-From: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane-mx.org@gnu.org Fri Apr 24 14:41:30 2020 Return-path: Envelope-to: geh-help-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 1jRxe4-000OOy-Lb for geh-help-gnu-emacs@m.gmane-mx.org; Fri, 24 Apr 2020 14:41:28 +0200 Original-Received: from localhost ([::1]:35062 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1jRxe3-0006Od-L8 for geh-help-gnu-emacs@m.gmane-mx.org; Fri, 24 Apr 2020 08:41:27 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:54672) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1jRxYn-0005Kc-O7 for help-gnu-emacs@gnu.org; Fri, 24 Apr 2020 08:36:02 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.90_1) (envelope-from ) id 1jRxYk-0006Qj-Sm for help-gnu-emacs@gnu.org; Fri, 24 Apr 2020 08:36:00 -0400 Original-Received: from sonic310-57.consmr.mail.ir2.yahoo.com ([77.238.177.30]:37076) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1jRxYk-0006E4-6c for help-gnu-emacs@gnu.org; Fri, 24 Apr 2020 08:35:58 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=yahoo.de; s=s2048; t=1587731753; bh=x70JCWLOCLgjMkaoPuX4Xg1lbVzjq97pixGKY5g3Kd8=; h=Date:From:To:Subject:References:From:Subject; b=coVIS+NrOS8UwkW22Xke0SKWyIdSexbHU2+DdPjtaIO7S26y89MnSmqDM3U1AXvu4O/53F9aC3e11zAnxiQLPWt/VV9tOIfUxId8DlsXKggnZBESIHTuLPztOlJ0jOlgtoKfUjdgZJhpSKM7UDpjmHjs2nCMU5ADH3iEEn3pEm7u6X/nljDE9irrk1Z2A/HBGFZXrmXlB/VpoaZAGjvsJ6kOQsSB+H3+oVZKarh5YWAccMKfBRuQInc9Gi2oeKvpf0IxyMY1z0bZUq1XQBmOzwxG9EnbpxR3KzGUVbsri6W4u/ZYnIMnByTeU9fY6GLPTDEVH4eewkNu9CqVgS/rWA== X-YMail-OSG: rbNkxjAVM1l0ijKCDW_NXMGKTgormSXKz7dSC9mUMOX8TLuJoHXzEqpxV90fJcH V.CzsF0JOGnkPMYeBs_7VJi.2UmfnznU9pUqIaY9UX.mzRsW3QBosDy.LG_aEC4A9zOVHjWqYaVG VNcnrN85x9bRXAQjmx_ymKcg40dyU3sXjupM289NKDUUcCeLC8d19Cwpq7IeZsM1M4bHx.cemXts 2SysifKWDPjcfR7A0wYmegLotKCKqWq7sRtgtGcMOjFm4ku8mzlv3rPS3QbZxhwVndTCGWXqK9f_ Wj0qJZrF9gGDrh0dozFB8hQUBfOh5IrgG7.ezMu6sbi4y9fuVSfgLPpbVfpdPt1GIoPORpwvMrBE eraTKRveuWfH7LeQcMoEKMIlKy18XABGGPjxQ9LSwank2Pem9za0kNV36cpGm46Rq3mpVxbW4Oho nhQwOxveN7TjndgBdNiaiQNaPmXsaYzK.UeNJuBna6kFu6TdgQeVU1w9hW3UdR0a.uJ4PSxZxJPX gRx5k0LqlPFro5G_ZlBh21ADuyNnEFfwSja4EWHc9H8JqizF4.8dvaQrD4gvC1fJvovSYAdBJs3T SmJ1JjE9ejvDCwDoMwDWwFSPqrSjNZaUur48h8qDYa2xAbc35r41XIiQop1Js8w2yUh5kria1Tcu bBVU.YKqyVaXwHjb7ajk0MC0PNP8FAAJZjmg4ul3KmxAPB7ArpMwCCuts6Ee6T8F3Oy4bUhUjEG_ cD9DLI678lsu4iWvXKBKSlwSqt9KjjdD4H9RwedQ9dKYmUsg3B_dQx46YKiTM9iVPxqAmnUW5oJn xc.H5SL4Ztd3jxlQmSf5UaRddJlFizKBsgrMl01vrd Original-Received: from sonic.gate.mail.ne1.yahoo.com by sonic310.consmr.mail.ir2.yahoo.com with HTTP; Fri, 24 Apr 2020 12:35:53 +0000 X-Mailer: WebService/1.1.15776 YMailNorrin Mozilla/5.0 (X11; Ubuntu; Linux x86_64; rv:75.0) Gecko/20100101 Firefox/75.0 Received-SPF: pass client-ip=77.238.177.30; envelope-from=rdiezmail-emacs@yahoo.de; helo=sonic310-57.consmr.mail.ir2.yahoo.com X-detected-operating-system: by eggs.gnu.org: First seen = 2020/04/24 08:35:54 X-ACL-Warn: Detected OS = Linux 3.1-3.10 X-Received-From: 77.238.177.30 X-BeenThere: help-gnu-emacs@gnu.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: Users list for the GNU Emacs text editor List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane-mx.org@gnu.org Original-Sender: "help-gnu-emacs" Xref: news.gmane.io gmane.emacs.help:122924 Archived-At: Hallo all: I am running a self-compiled Emacs version 26.2 on Ubuntu 18.04.4 LTS. I no= rmally use Bash as a shell. When I evaluate the following in Emacs: =C2=A0 (shell-quote-argument "a=3Db") I get: =C2=A0 "a\\=3Db" That's wrong, because it does not work in Bash: =C2=A0 $ echo "a\\=3Db" =C2=A0 a\=3Db But even if I am getting confused with Emacs' string escaping, echo "a\=3Db= " does not work either. I am looking for the equivalent in Emacs for Bash' printf "%q" escaping/quo= ting: =C2=A0 $ printf "%q" "a=3Db" =C2=A0 a=3Db I though I might just copy and modify shell-quote-argument, but it is too c= omplicated for my limited Lisp skills. I do not need any flexibility or configuration, I just need to emulate the = behaviour of Bash' printf "%q". Thanks in advance for any help, =C2=A0 rdiez