* Don't install the "nixpkgs_sys" symlink in ~/.nix-defexpr anymore.

Note that for attribute-based nix-env installations, the NixOS
  channel contains Nixpkgs as its "pkgs" attribute, so

    $ nix-env -iA nixos.pkgs.foo

  will work instead of the old

    $ nix-env -iA nixpkgs_sys.foo
    
* Fix the path to root's channels installed in ~/.nix-defexpr.

svn path=/nixos/trunk/; revision=33823
This commit is contained in:
Eelco Dolstra 2012-04-18 10:58:33 +00:00
parent a193fe4f1d
commit 7ba5881146

View File

@ -93,13 +93,12 @@ if test "$(stat --printf '%u' $NIX_USER_GCROOTS_DIR)" != "$(id -u)"; then
fi
# Set up a default Nix expression from which to install stuff.
if test ! -e $HOME/.nix-defexpr -o -L $HOME/.nix-defexpr; then
if [ ! -e $HOME/.nix-defexpr -o -L $HOME/.nix-defexpr ]; then
echo "creating $HOME/.nix-defexpr" >&2
rm -f $HOME/.nix-defexpr
mkdir $HOME/.nix-defexpr
ln -s /etc/nixos/nixpkgs $HOME/.nix-defexpr/nixpkgs_sys
if test "$USER" != root; then
ln -s /nix/var/nix/gcroots/per-user/root/channels $HOME/.nix-defexpr/channels_root
if [ "$USER" != root ]; then
ln -s /nix/var/nix/profiles/per-user/root/channels $HOME/.nix-defexpr/channels_root
fi
fi