all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: Kai.Grossjohann@CS.Uni-Dortmund.DE (Kai Großjohann)
Cc: emacs-devel@gnu.org
Subject: Re: shell-quote-argument: make it behave as if on Unix?
Date: Tue, 16 Apr 2002 11:25:49 +0200	[thread overview]
Message-ID: <vafn0w42dwi.fsf@INBOX.auto.emacs.devel.tok.lucy.cs.uni-dortmund.de> (raw)
In-Reply-To: <200204111453.g3BErBr21336@aztec.santafe.edu> (Richard Stallman's message of "Thu, 11 Apr 2002 08:53:11 -0600 (MDT)")

Richard Stallman <rms@gnu.org> writes:

>     The Tramp package sends commands to a remote Unix host.  These
>     commands sometimes include filenames, so I pass those through
>     shell-quote-argument.
>
> I think you should copy the code you want into your own source file
> and give it a different function name.

I've been thinking about this for a long time now, and I would like
to thank Richard for his very useful advice.  All things considered,
I think he is right.

OT1H it would be nice to reuse code.

But OTOH, there are a number of issues with shell-quote-argument as
it currently stands, and Tramp can only use it after these have been
decided.

(1) [This issue has been discussed in the current thread.]
    shell-quote-argument always quotes for the system that Emacs is
    running on, but some applications (such as Tramp) might wish to
    use the strings on a different system.

(2) shell-quote-argument does not deal well with newlines in strings.
    For instance, it converts "a\nb" into "a\\\nb" which the (Bourne)
    shell then reads as "ab".  There is no method (that I know of)
    which works for both Bourne-ish and c-ish shells on Unix.

So I will (maybe not today) change tramp-shell-quote-argument in such
a way that it does the work itself.  After that, it is not urgent to
change the behavior of shell-quote-argument.

Are people interested in me working on changing shell-quote-argument
to deal with the above two issues?  I'll look through the Lisp code
in Emacs to see that the change is upwardly¹ compatible.

kai

¹ Or is it "upwards-compatible"?
-- 
Silence is foo!

  parent reply	other threads:[~2002-04-16  9:25 UTC|newest]

Thread overview: 26+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2002-04-10 13:46 shell-quote-argument: make it behave as if on Unix? Kai Großjohann
2002-04-10 16:56 ` Eli Zaretskii
2002-04-10 21:10   ` Kai Großjohann
2002-04-10 21:29     ` Stefan Monnier
2002-04-12  3:11     ` Richard Stallman
2002-04-12  4:09       ` Stefan Monnier
2002-04-12 10:16         ` Eli Zaretskii
2002-04-12 11:43           ` Kim F. Storm
2002-04-12 15:18             ` Eli Zaretskii
2002-04-12 18:46           ` Stefan Monnier
2002-04-12 11:07   ` Kai Großjohann
2002-04-12 14:07     ` Kim F. Storm
2002-04-12 13:38       ` Kai Großjohann
2002-04-12 15:20         ` Eli Zaretskii
2002-04-12 16:55           ` Kai Großjohann
2002-04-12 18:51             ` Eli Zaretskii
2002-04-13 19:07               ` Richard Stallman
2002-04-13 19:18                 ` Kai Großjohann
2002-04-15 21:54                   ` Richard Stallman
2002-04-15 12:16                 ` Stefan Monnier
2002-04-16 20:17                   ` Richard Stallman
2002-04-11 14:53 ` Richard Stallman
2002-04-11 15:57   ` Kai Großjohann
2002-04-12 19:49     ` Richard Stallman
2002-04-16  9:25   ` Kai Großjohann [this message]
2002-04-16  9:35     ` Kai Großjohann

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=vafn0w42dwi.fsf@INBOX.auto.emacs.devel.tok.lucy.cs.uni-dortmund.de \
    --to=kai.grossjohann@cs.uni-dortmund.de \
    --cc=emacs-devel@gnu.org \
    /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.