From cecb6406197b3e90a5312dc309a32206fa5b76a7 Mon Sep 17 00:00:00 2001 From: Manuel Thalmann Date: Sun, 14 Jul 2024 03:05:26 +0200 Subject: [PATCH] Streamline `base-devel` installation --- scripts/Arch/OS/install.fish | 26 ++++++++++++---------- scripts/Arch/Software/base-devel/main.fish | 22 ++++++++++++++++++ 2 files changed, 36 insertions(+), 12 deletions(-) create mode 100644 scripts/Arch/Software/base-devel/main.fish diff --git a/scripts/Arch/OS/install.fish b/scripts/Arch/OS/install.fish index 9a17c9e3..12d0c134 100644 --- a/scripts/Arch/OS/install.fish +++ b/scripts/Arch/OS/install.fish @@ -1,16 +1,18 @@ #!/bin/env fish -set -l dir (status dirname) +begin + set -l dir (status dirname) -function initialize -V dir - "$dir/../Software/base-devel/install.sh" - "$dir/../Config/pacman/install.sh" - "$dir/../Software/yay/install.sh" -end - -if not type -q installSoftware - function installSoftware - "$dir/../Collections/personal.sh"; + function initialize -V dir + source "$dir/../Software/base-devel/main.fish" + "$dir/../Config/pacman/install.sh" + "$dir/../Software/yay/install.sh" end -end -source "$dir/../../Common/OS/install.fish" + if not type -q installSoftware + function installSoftware + "$dir/../Collections/personal.sh"; + end + end + + source "$dir/../../Common/OS/install.fish" +end diff --git a/scripts/Arch/Software/base-devel/main.fish b/scripts/Arch/Software/base-devel/main.fish new file mode 100644 index 00000000..714d8049 --- /dev/null +++ b/scripts/Arch/Software/base-devel/main.fish @@ -0,0 +1,22 @@ +#!/bin/env fish +begin + set -l dir (status dirname) + source "$dir/../../Scripts/software.fish" + + function installSW + pacinst -Syu base-devel + configureSW + end + + function configureSW + set -l customFile /etc/makepkg.conf.d/valhalla.conf + + if [ ! -f "$customFile" ] + begin + printf %s\n \ + "OPTIONS+=(!debug)" \ + "MAKEFLAGS=\"-j\$(nproc)\"" + end | sudo tee "$customFile" > /dev/null + end + end +end