From mboxrd@z Thu Jan 1 00:00:00 1970 From: Hartmut Goebel Subject: Re: string-append plus package Date: Mon, 19 Dec 2016 12:05:04 +0100 Message-ID: <42bb5a6c-6a7c-c348-d9d0-da83805cdffe@crazy-compilers.com> References: <20161208195647.GA23449@jasmine> <87h9608d3l.fsf@gnu.org> Mime-Version: 1.0 Content-Type: multipart/alternative; boundary="------------FA0E77ED6329E40B99444008" Return-path: Received: from eggs.gnu.org ([2001:4830:134:3::10]:56186) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1cIvkv-0002HS-Cp for help-guix@gnu.org; Mon, 19 Dec 2016 06:05:22 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1cIvkq-0000dc-Au for help-guix@gnu.org; Mon, 19 Dec 2016 06:05:21 -0500 In-Reply-To: <87h9608d3l.fsf@gnu.org> List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: help-guix-bounces+gcggh-help-guix=m.gmane.org@gnu.org Sender: "Help-Guix" To: =?UTF-8?Q?Ludovic_Court=c3=a8s?= Cc: help-guix@gnu.org This is a multi-part message in MIME format. --------------FA0E77ED6329E40B99444008 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Am 19.12.2016 um 10:47 schrieb Ludovic Court=C3=A8s: > The result of =E2=80=98file-append=E2=80=99 is not a string, but =E2=80= =98string-append=E2=80=99 expects > two strings, hence the error. > > =E2=80=98file-append=E2=80=99 returns a =E2=80=9Cstring-valued gexp=E2=80= =9D. This is to say that, in a > staging context, it will produce a string. For example: > > (scheme-file "foo" #~(foo bar #$(file-append nginx "/foo/bar"))) > > leads to a file =E2=80=9Cfoo=E2=80=9D containing: > > (foo bar "/gnu/store/=E2=80=A6-nginx-1.2.3/foo/bar") Thanks for the explanation (which to be frank would take me some time to understand). Please reread you answer from the point of view of an administrator or somebody else who is not a Scheme programmer. Somebody who just wants to get some system up an running. He would answer like this: Parton? What? "string-valued gexp", "staging context"? I do not care. I simply want to get the path to a file within a package. Whatever you write above may be correct and may be understandable for every Scheme programmer. But this is discouraging for everybody who does not want to become a Scheme expert for administering his/her systems. I already wasted about an hour just to try to get this path! This is crap= ! --=20 Regards Hartmut Goebel | Hartmut Goebel | h.goebel@crazy-compilers.com | | www.crazy-compilers.com | compilers which you thought are impossible | --------------FA0E77ED6329E40B99444008 Content-Type: text/html; charset=utf-8 Content-Transfer-Encoding: quoted-printable
Am 19.12.2016 um 10:47 schrieb Ludovic Court=C3=A8s:
The result of =E2=80=98file-append=E2=80=99 is not a=
 string, but =E2=80=98string-append=E2=80=99 expects
two strings, hence the error.

=E2=80=98file-append=E2=80=99 returns a =E2=80=9Cstring-valued gexp=E2=80=
=9D.  This is to say that, in a
staging context, it will produce a string.  For example:

  (scheme-file "foo" #~(foo bar #$(file-append nginx "/foo/bar")))

leads to a file =E2=80=9Cfoo=E2=80=9D containing:

  (foo bar "/gnu/store/=E2=80=A6-nginx-1.2.3/=
foo/bar")

Thanks for the explanation (which to be frank would take me some time to understand).

Please reread you answer from the point of view of an administrator or somebody else who is not a Scheme programmer. Somebody who just wants to get some system up an running. He would answer like this:

Parton? What? "string-valued gexp", "staging context"? I do not care. I simply want to get the path to a file within a package.

Whatever you write above may be correct and may be understandable for every Scheme programmer. But this is discouraging for everybody who does not want to become a Scheme expert for administering his/her systems.

I already wasted about an hour just to try to get this path! This is crap!

--=20
Regards
Hartmut Goebel

| Hartmut Goebel          | h.goebel@crazy-compilers.com   =
            |
| www.crazy-compilers.com | compilers which you thought are impo=
ssible |
--------------FA0E77ED6329E40B99444008--