[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
bug#20255: 'search-paths' should respect both user and system profile.
From: |
Ludovic Courtès |
Subject: |
bug#20255: 'search-paths' should respect both user and system profile. |
Date: |
Tue, 05 May 2015 14:35:01 +0200 |
User-agent: |
Gnus/5.13 (Gnus v5.13) Emacs/24.5 (gnu/linux) |
宋文武 <address@hidden> skribis:
> How about using a shell variable as input for the location:
> (replace /gnu/store/xxx with $GUIX_PROFILE)
>
> # etc/profile
> export PATH=$GUIX_PROFILE/bin:$PATH
> export MANPATH=$GUIX_PROFILE/share/man:$MANPATH
> ...
>
> Then when 'source' it, we pass the location:
> (we did know where $GUIX_PROFILE is when do the 'source')
>
> # ~/.bash_profile
> GUIX_PROFILE=$HOME/.guix-profile
> if [ -f $GUIX_PROFILE/etc/profile ]; then
> . $GUIX_PROFILE/etc/profile
> fi
>
> # /etc/profile
> GUIX_PROFILE=/run/current-system/profile
> source $GUIX_PROFILE/etc/profile
Yes, but we would also like users to be able to source
~/.guix-profile/etc/profile themselves directly, and it wouldn’t be nice
to ask them to set GUIX_PROFILE before sourcing it.
Ludo’.