gwl-devel
[Top][All Lists]
Advanced

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

Re: [gwl-devel] variable interpolation in code snippets


From: Ricardo Wurmus
Subject: Re: [gwl-devel] variable interpolation in code snippets
Date: Tue, 26 Feb 2019 09:12:25 +0100
User-agent: mu4e 1.0; emacs 26.1

zimoun <address@hidden> writes:

> A quick question. The `data-inputs` is a list, so `print
> "{{data-inputs}}` should return:
>      "sample.bam" "hg38.fa" "abc"
> Right?
>
> How to refer to "hg38.fa" only?
>
>    print "{{second data-inputs}}"

That’s not possible, unfortunately.  Currently, the list is merely
converted to a string, so (list "sample.bam" "hg38.fa" "abc") becomes
the string “sample.bam hg38.fa abc”.  For singleton lists that’s exactly
what you want, but it’s not great for longer lists.

I thought about adding support for selectors, but I don’t know if I
should.  Maybe it would be better to allow for named inputs instead,
which would result in process-local bindings.

This would probably require changes to the records macro that we took
from Guix.  I’d prefer that over implementing a small language in a
reader macro.

--
Ricardo




reply via email to

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