guix-devel
[Top][All Lists]
Advanced

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

Re: Export environment variables only in `guix environment`.


From: Fis Trivial
Subject: Re: Export environment variables only in `guix environment`.
Date: Thu, 1 Feb 2018 15:15:40 +0000

Pjotr Prins writes:

> On Thu, Feb 01, 2018 at 12:40:39AM +0100, Ludovic Courtès wrote:
>> Hello,
>> 
>> Fis Trivial <address@hidden> skribis:
>> 
>> > * Problem
>> > The exported environment variables can cause various problems in foreign
>> > distribution(1)(2). And besides, The long list of environment variables(4)
>> > injected into user's login shell makes the user's environment impure.
>> > So, I believe that if I want to run guix safely on a foreign 
>> > distributions, I
>> > need to eliminate the need for exporting environment variables from guix 
>> > to my
>> > login shell.
>
> Not a problem, just don't do it :). To import the invironments 
> run
>
>   . $PROFILE/etc/profile
>
> I do that in scripts or when I need something. Even so, many programs
> work with just the PATH set.
>
> Pj.

Currently my solution is separating the profile file into two parts, one
contains PATH and SSL related envs, the second part contains all the
others exported by guix. Then I source the first part in login shell
while the second part in interactive shell.

It's a little hack, which means not the way it should work, to me that's
a problem. Guix is still young, we don't have many legacy problems that
needs hacks to solve. I love guix project, which is elegant from the
choice of scripting language and the underlying functional logic. I hope
that if we be picky enough, Guix can stay this way. So lets eliminate
these hacks. :)

Thanks for your time.

reply via email to

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