about summary refs log tree commit diff
path: root/scripts/install-nix-from-closure.sh
diff options
context:
space:
mode:
authorGraham Christensen <graham@grahamc.com>2018-03-28T13·16-0400
committerGraham Christensen <graham@grahamc.com>2018-03-29T19·38-0400
commit2921165a9d14b80fd4a7e350e72ec2b83791682c (patch)
tree55f5959f870b4f06c3f6b9e816bd27b5febb7609 /scripts/install-nix-from-closure.sh
parent446bb88f13080eed131a1b0bd304c45a860a3fab (diff)
Expand the multi-user installer to support Linuxes with systemd
 - darwin installer: delete hardware report, not necessary
 - moves os-specific code from the darwin installer to to `poly_*`
   functions
 - adds profile.d support to the profile targets, which automatically
   handles many distros which don't have a /etc/bashrc but do have an
   /etc/profile.d
 - /bin/bash -> /usr/bin/env bash
 - document why each excluded shellcheck check is excluded
 - rename the multi-user to Daemon-based
Diffstat (limited to 'scripts/install-nix-from-closure.sh')
-rw-r--r--scripts/install-nix-from-closure.sh11
1 files changed, 9 insertions, 2 deletions
diff --git a/scripts/install-nix-from-closure.sh b/scripts/install-nix-from-closure.sh
index 3e5676f419ba..8416fb9673b5 100644
--- a/scripts/install-nix-from-closure.sh
+++ b/scripts/install-nix-from-closure.sh
@@ -29,8 +29,15 @@ if [ "$(uname -s)" = "Darwin" ]; then
         exit 1
     fi
 
-    printf '\e[1;31mSwitching to the Multi-User Darwin Installer\e[0m\n'
-    exec "$self/install-darwin-multi-user"
+    printf '\e[1;31mSwitching to the Daemon-based Installer\e[0m\n'
+    exec "$self/install-multi-user"
+    exit 0
+fi
+
+# Linux & Systemd support
+if [ "$(uname -s)" = "Linux" ] && [ -e /run/systemd/system ]; then
+    printf '\e[1;31mSwitching to the Daemon-based Installer\e[0m\n'
+    exec "$self/install-multi-user"
     exit 0
 fi