From ee4906cf4d03e190068f53536dfe15e348379746 Mon Sep 17 00:00:00 2001 From: Manuel Thalmann Date: Thu, 5 Dec 2024 10:33:06 +0100 Subject: [PATCH] Install valhalla dependencies during setup --- scripts/Arch/OS/setup.fish | 6 +++++- scripts/Arch/lib/dependencies.fish | 10 ++++++++-- 2 files changed, 13 insertions(+), 3 deletions(-) diff --git a/scripts/Arch/OS/setup.fish b/scripts/Arch/OS/setup.fish index c7ef6918..69a9057d 100755 --- a/scripts/Arch/OS/setup.fish +++ b/scripts/Arch/OS/setup.fish @@ -24,13 +24,15 @@ begin end function initOS -V dir + source "$dir/../lib/dependencies.fish" source "$dir/../../lib/wait-network.fish" + set -l mountDir (getOSConfig partition.rootDir) waitNetwork and pacman-key --init and pacman-key --populate - and pacstrap -K (getOSConfig partition.rootDir) \ + and pacstrap -K "$mountDir" \ base \ linux \ linux-firmware \ @@ -38,6 +40,8 @@ begin man-db \ man-pages \ texinfo + + installValhallaDeps "$mountDir" end function setupOS -S -V dir -S diff --git a/scripts/Arch/lib/dependencies.fish b/scripts/Arch/lib/dependencies.fish index c42f36ba..c890e99e 100644 --- a/scripts/Arch/lib/dependencies.fish +++ b/scripts/Arch/lib/dependencies.fish @@ -1,5 +1,11 @@ -function installValhallaDeps -V dir +function installValhallaDeps -V dir -a mountDir source "$dir/../lib/software.fish" - and pacinst fish git jq nix sudo tmux + set -l args + + if [ -n "$mountDir" ] + set -a args --root "$mountDir" + end + + and pacinst $args fish git jq nix sudo tmux sudo systemctl enable --now nix-daemon end