From 0747d2a784900a0f172f87b5643207c8262cf5f5 Mon Sep 17 00:00:00 2001 From: Menno van Leeuwen Date: Wed, 15 Jan 2025 12:52:40 +0100 Subject: [PATCH] enhance setup script to support continuation of installation process --- setup.sh | 19 ++++++++++++++----- 1 file changed, 14 insertions(+), 5 deletions(-) diff --git a/setup.sh b/setup.sh index 95aa173..ab152f5 100755 --- a/setup.sh +++ b/setup.sh @@ -301,7 +301,7 @@ install_nix() { fi log_success "Nix has been installed. We're reinvoking the script to continue setup." - curl -L https://df.mvl.sh | bash + curl -L https://df.mvl.sh | bash -s - -c exit 0 } @@ -446,6 +446,12 @@ main() { exit 0 fi + # Check if this is a continuation -c flag + if [ "$1" = "-c" ]; then + log_info "Continuing setup..." + CONTINUATION=true + fi + # Check prerequisites check_prerequisites @@ -456,10 +462,13 @@ main() { fi # Run setup steps - warning_prompt - prepare_hostname - check_selinux - install_nix + if [ "$CONTINUATION" != "true" ]; then + warning_prompt + prepare_hostname + check_selinux + install_nix + fi + install_home_manager setup_symlinks