all messages for Guix-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: Ricardo Wurmus <rekado@elephly.net>
To: Catonano <catonano@gmail.com>
Cc: help-guix <help-guix@gnu.org>
Subject: Re: tree doesn't get called
Date: Tue, 09 May 2017 19:20:40 +0200	[thread overview]
Message-ID: <87pofihrpz.fsf@elephly.net> (raw)
In-Reply-To: <CAJ98PDxt21DktXgG8jXkosTv_7jWubHm9dgfEhnkvxPP5OwjPQ@mail.gmail.com>


Catonano <catonano@gmail.com> writes:

>> Here’s a version that works for me:
>>
>>
>>                  ;; Compile .scm files and install.
>>                  (every (lambda (file)
>>                           (let ((go-file (string-append module-dir "/"
>>                                                         (basename file
>> ".scm") ".go")))
>>                             ;; Install source module.
>>                             (install-file file module-dir)
>>                             ;; Compile and install module.
>>                             (zero? (system* "guild" "compile" "-L" cwd
>>                                             "-o" go-file file))))
>>
>
> The differences with my version is that you use install-file insted of
> copy-file  and you pass the -L (cwd) switch to guild

These were mostly cosmetic changes.  I evaluate “(getcwd)” once and bind
it to “cwd” instead of evaluating it again and again for each file.
This is not what fixed the crash.

“install-file” only takes a file and a directory, unlike “copy-file”
which takes a source file name and a target file name.  I did this just
to simplify the code.

> I wonder what was causing my issue ?

Another difference is that I’m using “basename”.  Your use of “match”
didn’t work, because the match pattern wasn’t correct for the
“find-files” case.

--
Ricardo

GPG: BCA6 89B6 3655 3801 C3C6  2150 197A 5888 235F ACAC
https://elephly.net

  parent reply	other threads:[~2017-05-09 17:20 UTC|newest]

Thread overview: 16+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-05-05 15:50 tree doesn't get called Catonano
2017-05-05 22:24 ` Eric Bavier
2017-05-08  5:02   ` Catonano
2017-05-08  6:08     ` Ricardo Wurmus
2017-05-08 17:14       ` Catonano
2017-05-08 17:45         ` Catonano
2017-05-08 20:19         ` Ricardo Wurmus
2017-05-09 15:41           ` Catonano
2017-05-09 15:43             ` Catonano
2017-05-10 19:51               ` Ricardo Wurmus
2017-05-11  4:20                 ` Catonano
2017-05-09 17:20             ` Ricardo Wurmus [this message]
2017-05-09 18:12               ` Catonano
2017-05-08  7:34 ` Mark H Weaver
2017-05-08 17:28   ` Catonano
2017-05-08 17:58     ` Ricardo Wurmus

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=87pofihrpz.fsf@elephly.net \
    --to=rekado@elephly.net \
    --cc=catonano@gmail.com \
    --cc=help-guix@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/guix.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.