diff --git a/scripts/nix-profile.sh.in b/scripts/nix-profile.sh.in index e868399b1..82488c172 100644 --- a/scripts/nix-profile.sh.in +++ b/scripts/nix-profile.sh.in @@ -1,11 +1,16 @@ # This file is tested by tests/installer/default.nix. -if [ -n "$HOME" ] && [ -n "$USER" ]; then +if [ -n "${HOME-}" ] && [ -n "${USER-}" ]; then # Set up the per-user profile. +<<<<<<< HEAD NIX_LINK="$HOME/.nix-profile" if [ -n "${XDG_STATE_HOME-}" ]; then NIX_LINK_NEW="$XDG_STATE_HOME/nix/profile" +======= + if [ -n "${NIX_STATE_HOME-}" ]; then + NIX_LINK="$NIX_STATE_HOME/profile" +>>>>>>> 97fffd876 (nix-profile.sh.in: fix envvar condition) else NIX_LINK_NEW="$HOME/.local/state/nix/profile" fi