From mboxrd@z Thu Jan 1 00:00:00 1970 From: Catonano Subject: Re: tree doesn't get called Date: Mon, 8 May 2017 19:14:24 +0200 Message-ID: References: <20170505172459.158487fc@openmailbox.org> <87y3u7khhu.fsf@elephly.net> Mime-Version: 1.0 Content-Type: multipart/alternative; boundary=94eb2c1981f2fa6480054f065e05 Return-path: Received: from eggs.gnu.org ([2001:4830:134:3::10]:48235) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1d7mEu-00028T-43 for help-guix@gnu.org; Mon, 08 May 2017 13:14:29 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1d7mEs-00060F-SV for help-guix@gnu.org; Mon, 08 May 2017 13:14:28 -0400 Received: from mail-wm0-x22d.google.com ([2a00:1450:400c:c09::22d]:38184) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1d7mEs-0005zz-HN for help-guix@gnu.org; Mon, 08 May 2017 13:14:26 -0400 Received: by mail-wm0-x22d.google.com with SMTP id 142so72554568wma.1 for ; Mon, 08 May 2017 10:14:26 -0700 (PDT) In-Reply-To: <87y3u7khhu.fsf@elephly.net> 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: Ricardo Wurmus Cc: help-guix --94eb2c1981f2fa6480054f065e05 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable 2017-05-08 8:08 GMT+02:00 Ricardo Wurmus : > > > It looks like you first need to create the target directory (with > =E2=80=9Cmkdir-p=E2=80=9D). > wonderful, thanks > > BTW: instead of an explicit list for scm-files you could use this: > > (find-files "." "\\.scm$") > Thanks, Ricardo. This is the new error ice-9/eval.scm:386:9: In procedure eval: ice-9/eval.scm:386:9: Throw to key `match-error' with args `("match" "no matching pattern" ("" "/include" "scm"))'. I guess the culprit is this (for-each (lambda (file) (let* ((dest-file ...) (go-file (match (string-split file #\.) ((base _) (string-append module-dir "/" base ".go")))))...))) The first file processed is "include.scm" I'm not sure what "no matching pattern" means The spliitting in "include" and "scm" seems corretc (where does that slash come from ?) And i I switch back to the explicit list of files, I get: wrote `/gnu/store/mdirmfqcs2cadk8ram89j7i0z9zlrqvb-guile-miniadapton-master/share= /guile/site/2.2/include.go' So the first file ("include.scm") gets correctly written But then: Backtrace: In ice-9/boot-9.scm: 160: 16 [catch #t # ...] In unknown file: ?: 15 [apply-smob/1 #] In ice-9/boot-9.scm: 66: 14 [call-with-prompt prompt0 ...] In ice-9/eval.scm: 432: 13 [eval # #] In ice-9/boot-9.scm: 2412: 12 [save-module-excursion #] 4089: 11 [#] 1734: 10 [%start-stack load-stack #] 1739: 9 [#] In unknown file: ?: 8 [primitive-load "/gnu/store/a0z8jd9sxxi6gnip6sfhrm3i06s6c9vv-guile-miniadapton-master-guile= -builder"] In ice-9/eval.scm: 387: 7 [eval # ()] In srfi/srfi-1.scm: 827: 6 [every1 # ...] In /gnu/store/a42pfdz8w5qxdkp6xz8783ydywmp0p8p-module-import/guix/build/gnu-bu= ild-system.scm: 653: 5 [# #] In ice-9/eval.scm: 432: 4 [eval # #] In ice-9/boot-9.scm: 778: 3 [for-each # #] In ice-9/eval.scm: 399: 2 [eval # #] 387: 1 [eval # #] In unknown file: ?: 0 [0 0] ERROR: In procedure 0: ERROR: Wrong type to apply: 0 what does this error message mean ? Why the second file causes an error ? Maybe I'm being petty, I'm sorry I'm just a bit confused --94eb2c1981f2fa6480054f065e05 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable
2017-05-08 8:08 GMT+02:00 Ricardo Wurmus <rekado@elephly= .net>:


It looks like you first need to create the target directory (with =E2=80=9Cmkdir-p=E2=80=9D).

wonderful, = thanks
=C2=A0

BTW: instead of an explicit list for scm-files you could use this:

=C2=A0 =C2=A0 (find-files "." "\\.scm$")

Thanks, Ricardo.

This is the new error

ice-9/eval.scm:386:9: In proc= edure eval:
ice-9/eval.scm:386:9: Throw to key `match-error' with ar= gs `("match" "no matching pattern" ("" "= /include" "scm"))'.


I guess the culprit is this


(for-each (lambda (file)
= =C2=A0=C2=A0=C2=A0 =C2=A0=C2=A0=C2=A0 (let* ((dest-file ...)
=C2=A0=C2= =A0=C2=A0 =C2=A0=C2=A0=C2=A0 =C2=A0=C2=A0 (go-file (match (string-split fil= e #\.)
=C2=A0=C2=A0=C2=A0 =C2=A0=C2=A0=C2=A0 =C2=A0=C2=A0=C2=A0 =C2=A0= =C2=A0=C2=A0 =C2=A0=C2=A0 ((base _)
=C2=A0=C2=A0=C2=A0 =C2=A0=C2=A0=C2= =A0 =C2=A0=C2=A0=C2=A0 =C2=A0=C2=A0=C2=A0 =C2=A0=C2=A0=C2=A0 (string-append= module-dir "/" base ".go")))))...)))

The first file processed is "include.scm"<= br>
I'm not sure what "no matc= hing pattern" means
The spliitting= in "include" and "scm" seems corretc (where does that = slash come from ?)

And i I switch b= ack to the explicit list of files, I get:

wrote `/gnu/store/mdirmfqc= s2cadk8ram89j7i0z9zlrqvb-guile-miniadapton-master/share/guile/site/2.2/incl= ude.go'

So the first file (&quo= t;include.scm") gets correctly written

But then:

Backtrace:
In ice-9/boot-9.scm:
=C2=A0160: = 16 [catch #t #<catch-closure 8c5dc0> ...]
In unknown file:
=C2= =A0=C2=A0 ?: 15 [apply-smob/1 #<catch-closure 8c5dc0>]
In ice-9/bo= ot-9.scm:
=C2=A0 66: 14 [call-with-prompt prompt0 ...]
In ice-9/eval.= scm:
=C2=A0432: 13 [eval # #]
In ice-9/boot-9.scm:
2412: 12 [save-= module-excursion #<procedure 8e6840 at ice-9/boot-9.scm:4084:3 ()>]4089: 11 [#<procedure 8e6840 at ice-9/boot-9.scm:4084:3 ()>]
173= 4: 10 [%start-stack load-stack #<procedure 8f6e20 at ice-9/boot-9.scm:40= 80:10 ()>]
1739: 9 [#<procedure 8f8960 ()>]
In unknown file:=
=C2=A0=C2=A0 ?: 8 [primitive-load "/gnu/store/a0z8jd9sxxi6gnip6sfh= rm3i06s6c9vv-guile-miniadapton-master-guile-builder"]
In ice-9/eval= .scm:
=C2=A0387: 7 [eval # ()]
In srfi/srfi-1.scm:
=C2=A0827: 6 [e= very1 #<procedure c7d2e0 at /gnu/store/a42pfdz8w5qxdkp6xz8783ydywmp0p8p-= module-import/guix/build/gnu-build-system.scm:649:9 (expr)> ...]
In /= gnu/store/a42pfdz8w5qxdkp6xz8783ydywmp0p8p-module-import/guix/build/gnu-bui= ld-system.scm:
=C2=A0653: 5 [#<procedure c7d2e0 at /gnu/store/a42pfdz= 8w5qxdkp6xz8783ydywmp0p8p-module-import/guix/build/gnu-build-system.scm:649= :9 (expr)> #]
In ice-9/eval.scm:
=C2=A0432: 4 [eval # #]
In ice= -9/boot-9.scm:
=C2=A0778: 3 [for-each #<procedure ecda50 at ice-9/eva= l.scm:416:20 (a)> #]
In ice-9/eval.scm:
=C2=A0399: 2 [eval # #]=C2=A0387: 1 [eval # #]
In unknown file:
=C2=A0=C2=A0 ?: 0 [0 0]
=
ERROR: In procedure 0:
ERROR: Wrong type to apply: 0


what does this error message mean ?

Why the second file causes an error ?

=
Maybe I'm being petty, I'm sorry
I'm just a bit confused
--94eb2c1981f2fa6480054f065e05--