[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
bug#40872: First installed package on guix system is not instantly usabl
From: |
Marius Bakke |
Subject: |
bug#40872: First installed package on guix system is not instantly usable |
Date: |
Sat, 02 May 2020 16:20:12 +0200 |
User-agent: |
Notmuch/0.29.3 (https://notmuchmail.org) Emacs/26.3 (x86_64-pc-linux-gnu) |
Stefan <address@hidden> writes:
> Hi Marius!
>
>> This is odd, as /etc/profile contains a workaround for this exact
>> problem (notice the else clause):
>>
>> # Arrange so that ~/.config/guix/current comes first.
>> for profile in "$HOME/.guix-profile" "$HOME/.config/guix/current"
>> do
>> if [ -f "$profile/etc/profile" ]
>> then
>> # Load the user profile's settings.
>> GUIX_PROFILE="$profile" ; \
>> . "$profile/etc/profile"
>> else
>> # At least define this one so that basic things just work
>> # when the user installs their first package.
>> export PATH="$profile/bin:$PATH"
>> fi
>> done
>>
>> Can you investigate why this is ineffective on your system?
>
> Previously I had some packages installed, but I rolled-back to generation 0.
> I found this in my scroll-back buffer:
>
> stefan@guix ~/development/guix$ guix package --roll-back
> Folgende Ableitung wird erstellt:
> /gnu/store/l0n6l104ldj7nz6kdyi7l8v5yjnc9p9g-profile.drv
> building profile with 0 packages...
> Von Generation „1“ zu „0“ gewechselt
>
> By rolling back it created a new generation 0 profile which is now lying
> around with this kind of empty file:
>
> stefan@guix ~$ cat .guix-profile/etc/profile
> # Source this file to define all the relevant environment variables in Bash
> # for this profile. You may want to define the 'GUIX_PROFILE' environment
> # variable to point to the "visible" name of the profile, like this:
> #
> # GUIX_PROFILE=/path/to/profile ; \
> # source /path/to/profile/etc/profile
> #
> # When GUIX_PROFILE is undefined, the various environment variables refer
> # to this specific profile generation.
>
> So the test for the existence of this file does not fail, but it doesn't
> change PATH either. This is the profile content, it has no bin/ folder to add
> to PATH:
I see. We could extend the test in /etc/profile to look for a /bin
directory of the profile, but arguably rolling back to generation 0 is
not a very common case. So I'm in favor of just keeping the status quo.
WDYT?
signature.asc
Description: PGP signature
- bug#40872: First installed package on guix system is not instantly usable,
Marius Bakke <=