Hey Efraim, Efraim Flashner <efr...@flashner.co.il> writes:
> On Mon, Oct 31, 2022 at 12:18:50AM -0700, Tom Willemse wrote: >> Hey Guix \o/ >> >> I've been wanting to package one of my little scripts in Guix Home and >> it uses a little library I wrote for SCSH. I've been looking at how >> Search Paths work and I'm having trouble figuring out how to make this >> work. >> >> Search paths seem easy enough generally, I was able to add a simple >> addition to my configuration by just adding this to the scsh package >> definition: >> >> (native-search-paths >> (list (search-path-specification >> (variable "SCSH_LIB_DIRS") >> (files '("share/scsh/site"))))) > > Try adding the 'separator' field, so it would look like this: > > (native-search-paths > (list (search-path-specification > (variable "SCSH_LIB_DIRS") > (separator " ") > (files '("share/scsh/site"))))) Thanks for the suggestion! Unfortunately this gets me a value of `SCSH_LIB_DIRS' like /home/chelys/.guix-home/profile/share/scsh-0.7 which, when I try the command `scsh -ll mpd.scm -o mpd' causes the following error to appear: error: Illegal path element in $SCSH_LIB_DIRS $SCSH_LIB_DIRS: /home/chelys/.guix-home/profile/share/scsh-0.7 The following element is not a string or #f: /home/chelys/.guix-home/profile/share/scsh-0.7 It's because SCSH treats the contents of `SCSH_LIB_DIRS' as "a sequence of of s-expressions, which are `read' from the string"[1] and supports either string values or the value #f. So `SCSH_LIB_DIRS' would have to be in this case: "/home/chelys/.guix-home/profile/share/scsh-0.7" I guess this just isn't supported as yet in Guix? Cheers, Tom