From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: David Kastrup Newsgroups: gmane.emacs.devel Subject: Re: [PATCH] Add shell-quasiquote. Date: Thu, 22 Oct 2015 09:03:32 +0200 Message-ID: <871tcnz8or.fsf@fencepost.gnu.org> References: <87si59wj42.fsf@T420.taylan> <5626622A.3090707@yandex.ru> <87zizdijbp.fsf@T420.taylan> <56267302.7050606@yandex.ru> <87io61igyu.fsf@T420.taylan> <56267CDF.6010201@yandex.ru> <87wpuhh15s.fsf@T420.taylan> <562683B9.1060305@yandex.ru> <83y4exe71v.fsf@gnu.org> <87y4ewoqbs.fsf@fastmail.com> <83si54e2qx.fsf@gnu.org> <87y4ew8fue.fsf@fastmail.com> <83zizcurco.fsf@gnu.org> <87k2qgw3q1.fsf@fastmail.com> <83lhawuny4.fsf@gnu.org> <8737x4vyyg.fsf@fastmail.com> <83bnbsujqd.fsf@gnu.org> <87y4ewujf8.fsf@fastmail.com> <837fmguixu.fsf@gnu.org> <87twpkhugn.fsf@fastmail.com> <8337x3vd8d.fsf@gnu.org> NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: text/plain X-Trace: ger.gmane.org 1445498902 5935 80.91.229.3 (22 Oct 2015 07:28:22 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Thu, 22 Oct 2015 07:28:22 +0000 (UTC) Cc: Random832 , emacs-devel@gnu.org To: Eli Zaretskii Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Thu Oct 22 09:28:21 2015 Return-path: Envelope-to: ged-emacs-devel@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by plane.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1ZpAIN-0003SS-8M for ged-emacs-devel@m.gmane.org; Thu, 22 Oct 2015 09:28:19 +0200 Original-Received: from localhost ([::1]:57168 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ZpAIM-0005XY-BT for ged-emacs-devel@m.gmane.org; Thu, 22 Oct 2015 03:28:18 -0400 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:42100) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ZpAGt-0003kn-Mp for emacs-devel@gnu.org; Thu, 22 Oct 2015 03:26:48 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1ZpAGs-0008Te-Ru for emacs-devel@gnu.org; Thu, 22 Oct 2015 03:26:47 -0400 Original-Received: from fencepost.gnu.org ([2001:4830:134:3::e]:53330) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ZpAGq-0008Si-CY; Thu, 22 Oct 2015 03:26:44 -0400 Original-Received: from localhost ([127.0.0.1]:38914 helo=lola) by fencepost.gnu.org with esmtp (Exim 4.82) (envelope-from ) id 1ZpAGo-00006D-TV; Thu, 22 Oct 2015 03:26:43 -0400 Original-Received: by lola (Postfix, from userid 1000) id 90D72DF494; Thu, 22 Oct 2015 09:03:32 +0200 (CEST) In-Reply-To: <8337x3vd8d.fsf@gnu.org> (Eli Zaretskii's message of "Thu, 22 Oct 2015 05:38:58 +0300") User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/25.0.50 (gnu/linux) X-detected-operating-system: by eggs.gnu.org: Error: Malformed IPv6 address (bad octet value). X-Received-From: 2001:4830:134:3::e X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Original-Sender: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.devel:192354 Archived-At: Eli Zaretskii writes: >> From: Random832 >> Date: Wed, 21 Oct 2015 15:50:32 -0400 >> >> Eli Zaretskii writes: >> > Sorry, you lost me. If it's not Emacs who will interpret the command, >> > then it must be some real shell. So are you talking about forcing >> > Emacs to run /bin/sh and nothing else? If so, you can simply bind >> > shell-file-name to that (and maybe also bind shell-command-switch >> > accordingly). Or am I (again) missing something? >> >> /bin/sh might not be a POSIX shell. on Solaris you need >> /usr/xpg4/bin/sh. And you might need environment variables set such as >> POSIXLY_CORRECT or PATH to get POSIX behavior from all utilities. > > OK, but that still boils down to binding some more variables. If we > want to help users with these factoids, we could have a small database > of the known Posix shells and their requirements. I think that's overdoing it with regard to shell-quote-argument and friends. We don't need a full POSIX shell, just something with the most basic quoting conventions of it. /bin/sh should be fine here. That's all the guarantee you get for calling commands/scripts with `system'. I don't think we should require more than that or try providing some guarantees in that regard. -- David Kastrup