From 92b9493807f302e4f51e708a53dd323ea0bffc40 Mon Sep 17 00:00:00 2001 From: exu Date: Fri, 17 Nov 2023 18:19:47 +0100 Subject: [PATCH] Make scripts less path dependent --- arch-config/scripts/arch-config.sh | 5 ++++- arch-setup/install.sh | 3 ++- 2 files changed, 6 insertions(+), 2 deletions(-) diff --git a/arch-config/scripts/arch-config.sh b/arch-config/scripts/arch-config.sh index 4f17a809..74206cdf 100755 --- a/arch-config/scripts/arch-config.sh +++ b/arch-config/scripts/arch-config.sh @@ -49,6 +49,9 @@ cat </dev/null # check if the install scripts are the same # NOTE Arguments get passed automatically now -if ! cmp --silent "$HOME/scripts/arch-config.sh" "$HOME/configs/arch-config/scripts/arch-config.sh"; then +if ! cmp --silent "$scriptloc" "$HOME/configs/arch-config/scripts/arch-config.sh"; then echo Removed old config file and launched new one. rm "$HOME/scripts/arch-config.sh" && cp "$HOME/configs/arch-config/scripts/arch-config.sh" "$HOME/scripts/" && bash ~/scripts/arch-config.sh "$@" fi diff --git a/arch-setup/install.sh b/arch-setup/install.sh index 24d803d4..f1e11bad 100755 --- a/arch-setup/install.sh +++ b/arch-setup/install.sh @@ -408,7 +408,8 @@ fi fc-cache -f echo Setting config -bash ~/configs/arch-config/install.sh +# FIXME not found +bash "$setupdir/../arch-config/install.sh" if [[ $(pacman -Q pkgstats 2>/dev/null >/dev/null) ]]; then pkgstats