[Nix-dev] nix-env has different nix-expressions based on the use issuing the command

Joachim Schiele js at lastlog.de
Wed Sep 26 13:40:27 CEST 2012


On 09/25/2012 02:28 PM, Lluís Batlle i Rossell wrote:
> On Tue, Sep 25, 2012 at 01:23:48PM +0200, Joachim Schiele wrote:
>> dear nixers,
>>
>> can someone please explain what is going wrong here?
>>
>> root # nix-env -qa '*' | grep chromium
>> chromium-21.0.1180.89
>> chromium-21.0.1180.89-with-plugins
>>
>> normal user # nix-env -qa '*' | grep chromium
>> chromium-19.0.1061.0-pre124950
>> chromium-19.0.1061.0-pre124950-with-plugins
>>
>> it seems that root has a different set of nix expressions compared to
>> what my normal user account offers. why ist that?
>
> The answer is inside ~/.nix-defexpr

thanks, that solved my problem!

for the record:

== before i typed 'mv .nix-defexpr .nix-defexpr_'
% ls -la .nix-defexpr
total 16
drwxr-xr-x   2 joachim users  4096 Mar 20  2012 ./
drwxr-xr-x 102 joachim users 12288 Sep 26 11:36 ../
lrwxrwxrwx   1 joachim users    43 Mar 20  2012 channels_root -> 
/nix/var/nix/gcroots/per-user/root/channels/
lrwxrwxrwx   1 joachim users    18 Mar 20  2012 nixpkgs_sys -> 
/etc/nixos/nixpkgs

== after i typed 'mv .nix-defexpr .nix-defexpr_ and used a ctrl+alt+f1 
shell for temporal login (which then regenerates .nix-defexpr)'

% ls -la .nix-defexpr
total 16
drwxr-xr-x   2 joachim users  4096 Sep 26 11:35 ./
drwxr-xr-x 102 joachim users 12288 Sep 26 11:36 ../
lrwxrwxrwx   1 joachim users    44 Sep 26 11:35 channels_root -> 
/nix/var/nix/profiles/per-user/root/channels/


More information about the nix-dev mailing list