guix-devel
[Top][All Lists]
Advanced

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

Re: guix-shell?


From: Ludovic Courtès
Subject: Re: guix-shell?
Date: Thu, 18 Sep 2014 10:00:00 +0200
User-agent: Gnus/5.130011 (Ma Gnus v0.11) Emacs/24.3 (gnu/linux)

David Thompson <address@hidden> skribis:

> I started working on this.  As a test, I wrote a script that loads a
> list of packages from a file, builds them, and then outputs the search
> paths.  One crucial search path is missing though: PATH.

The reason why it’s missing is that, search path specifications are
attached to packages, but there’s no obvious package to attach ‘PATH’
to.

However, it would be easy, and perhaps desirable, to change
‘search-path-environment-variables’ in package.scm to do that.

> Should 'guix environment' create a new profile with all of the
> necessary packages in it?  IIRC, nix shell doesn't do this, but I
> don't fully understand why and how.

The thing is, all the packages in question must be registered as GC
roots, at least for the duration of the shell session (otherwise they
could disappear.)

The easiest way to do that is to build a profile, and then register this
profile as a GC root (like what ‘guix build -r’ does.)

Another option would be to keep the connection to the daemon open (this
is possible if and only if ‘guix environment’ spawns the shell by
itself.)  Not so great, though.

HTH,
Ludo’.



reply via email to

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