aboutsummaryrefslogtreecommitdiff
path: root/scripts/install-nix-from-closure.sh
diff options
context:
space:
mode:
authorDomen Kožar <domen@dev.si>2020-05-26 15:49:26 +0200
committerDomen Kožar <domen@dev.si>2020-05-26 15:49:26 +0200
commit1a5ac894e929cefceec22c0f1ca248ee6be445ff (patch)
treea64be102a1aac1783f863d87f4e90f2b59d63386 /scripts/install-nix-from-closure.sh
parent909bdfb4b4208a65639ebe6548d37ba56fcd5353 (diff)
Fix installer script bugs
- --no-channel-add didn't have effect on multi-user installation - some new flags didn't work at all - document all installer flags
Diffstat (limited to 'scripts/install-nix-from-closure.sh')
-rw-r--r--scripts/install-nix-from-closure.sh13
1 files changed, 8 insertions, 5 deletions
diff --git a/scripts/install-nix-from-closure.sh b/scripts/install-nix-from-closure.sh
index 635aaa16d..826ca8b8c 100644
--- a/scripts/install-nix-from-closure.sh
+++ b/scripts/install-nix-from-closure.sh
@@ -41,7 +41,6 @@ fi
INSTALL_MODE=no-daemon
CREATE_DARWIN_VOLUME=0
-NIX_EXTRA_CONF=
# handle the command line flags
while [ $# -gt 0 ]; do
case $1 in
@@ -50,20 +49,20 @@ while [ $# -gt 0 ]; do
--no-daemon)
INSTALL_MODE=no-daemon;;
--no-channel-add)
- NIX_INSTALLER_NO_CHANNEL_ADD=1;;
+ export NIX_INSTALLER_NO_CHANNEL_ADD=1;;
--daemon-user-count)
- NIX_USER_COUNT=$2
+ export NIX_USER_COUNT=$2
shift;;
--no-modify-profile)
NIX_INSTALLER_NO_MODIFY_PROFILE=1;;
--darwin-use-unencrypted-nix-store-volume)
CREATE_DARWIN_VOLUME=1;;
--nix-extra-conf-file)
- NIX_EXTRA_CONF=$(cat $2)
+ export NIX_EXTRA_CONF="$(cat $2)"
shift;;
*)
(
- echo "Nix Installer [--daemon|--no-daemon] [--no-channel-add] [--no-modify-profile]"
+ echo "Nix Installer [--daemon|--no-daemon] [--daemon-user-count INT] [--no-channel-add] [--no-modify-profile] [--darwin-use-unencrypted-nix-store-volume] [--nix-extra-conf-file FILE]"
echo "Choose installation method."
echo ""
@@ -82,6 +81,10 @@ while [ $# -gt 0 ]; do
echo " --no-modify-profile: Skip channel installation. When not provided nixpkgs-unstable"
echo " is installed by default."
echo ""
+ echo " --daemon-user-count: Number of build users to create. Defaults to 32."
+ echo ""
+ echo " --nix-extra-conf-file: Path to nix.conf to prepend when installing /etc/nix.conf"
+ echo ""
) >&2
# darwin and Catalina+