guix-patches
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[bug#56050] [PATCH v2 1/2] etc/guix-install.sh: Initialize XDG base dire


From: Ludovic Courtès
Subject: [bug#56050] [PATCH v2 1/2] etc/guix-install.sh: Initialize XDG base directories.
Date: Mon, 04 Jul 2022 23:01:34 +0200
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/28.1 (gnu/linux)

"Philip McGrath" <philip@philipmcgrath.com> skribis:

> AFAICT, this seems to work. I think this is because of a rule I didn't know 
> about before from the section "Here Documents" under `info 
> "(bash)Redirections"`:
>
>> If any part of *word* is quoted, the *delimiter* is the result of
>> quote removal on *word*, and the lines in the here-document
>> are not expanded.
>
> and the beginning EOF is quoted, so it works like this:
>
> $ cat quoted-here-doc.sh 
> #!/bin/sh
> cat <<"EOF" > out.sh
> export PATH="$PATH:foobar"
> EOF
> $ ./quoted-here-doc.sh 
> $ cat out.sh 
> export PATH="$PATH:foobar"
>
> I'm certainly no expert on shell quoting, though.

Woow, I learned something, thanks!  Crazy.  (I wonder what Dash does
with that, given that it doesn’t support multi-digit file descriptor
numbers for redirects…)

Ludo’.





reply via email to

[Prev in Thread] Current Thread [Next in Thread]