all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: <tomas@tuxteam.de>
To: Bruno Barbier <brubar.cs@gmail.com>
Cc: Eric Abrahamsen <eric@ericabrahamsen.net>,
	chad <yandros@gmail.com>, Jean Louis <bugs@gnu.support>,
	emacs-devel@gnu.org
Subject: Re: Question about start-process and argument list
Date: Sat, 4 Feb 2023 07:40:12 +0100	[thread overview]
Message-ID: <Y939zHCliciPqPXz@tuxteam.de> (raw)
In-Reply-To: <63dd9297.df0a0220.2f942.ab1f@mx.google.com>

[-- Attachment #1: Type: text/plain, Size: 1353 bytes --]

On Sat, Feb 04, 2023 at 12:02:35AM +0100, Bruno Barbier wrote:
> Eric Abrahamsen <eric@ericabrahamsen.net> writes:
> 
> > chad <yandros@gmail.com> writes:
> >
> >> On Fri, Feb 3, 2023 at 4:23 PM Eric Abrahamsen <eric@ericabrahamsen.net>
> >> wrote:
> >>
> >>>
> >>> Kind of sounds like I should be using `start-process-shell-command'
> >>> again! As I understand it, this is its main selling point.
> >>>
> >>
> >> Have you by chance looked at shell-quote-argument or
> >> split-string-shell-command?  It's been a while since I had to deal with
> >> this, but I recall the former being helpful then, and it looks like it may
> >> be meant to handle your situation.
> >
> > But, to be clear, my problem doesn't seem to be escaping/unescaping
> > shell-specific characters, as far as I can see that isn't causing the
> > trouble. It's passing in the search query as a single argument, when it
> > contains spaces. It works fine when it's a single string with no spaces
> > in it.
> 
> But, if you go the `start-process-shell-command' way, shell escaping is
> going to be *your* problem (for any possible meaning of shell).
> 
> And, in this case, you should really consider using
> `shell-quote-argument'.

It /does/ help with whitespaces:

  (shell-quote-argument "foo bar baz")
  => "foo\\ bar\\ baz"

Cheers
-- 
t

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 195 bytes --]

  parent reply	other threads:[~2023-02-04  6:40 UTC|newest]

Thread overview: 13+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-02-03  3:48 Question about start-process and argument list Eric Abrahamsen
2023-02-03 11:24 ` Jean Louis
2023-02-03 19:24   ` Bruno Barbier
2023-02-03 21:23     ` Eric Abrahamsen
2023-02-03 21:34       ` chad
2023-02-03 22:54         ` Eric Abrahamsen
2023-02-03 23:02           ` Bruno Barbier
2023-02-04  2:20             ` Eric Abrahamsen
2023-02-04  6:40             ` tomas [this message]
2023-02-04  7:22       ` Jean Louis
2023-02-04 18:25         ` Eric Abrahamsen
2023-02-04  7:18     ` Jean Louis
2023-02-04 18:13       ` Eric Abrahamsen

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=Y939zHCliciPqPXz@tuxteam.de \
    --to=tomas@tuxteam.de \
    --cc=brubar.cs@gmail.com \
    --cc=bugs@gnu.support \
    --cc=emacs-devel@gnu.org \
    --cc=eric@ericabrahamsen.net \
    --cc=yandros@gmail.com \
    /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.