From 1fad8c59e161c1274724218b42d2c5a01daaee18 Mon Sep 17 00:00:00 2001 From: RealStickman Date: Wed, 20 Jul 2022 11:21:42 +0200 Subject: [PATCH] Add check if selectedpkgs files exist --- arch-setup/install.sh | 16 ++++++++++------ 1 file changed, 10 insertions(+), 6 deletions(-) diff --git a/arch-setup/install.sh b/arch-setup/install.sh index 3657b88a..763d0075 100755 --- a/arch-setup/install.sh +++ b/arch-setup/install.sh @@ -323,14 +323,18 @@ echo Installed wine echo Installing selected programs # install selected packages -echo Installing from official repository -# NOTE || true to continue if no packages have been selected -sudo pacman -S --needed - < "$setupdir/selectedpkgs.txt" || true +if [ -f "$setupdir/selectedpkgs.txt" ]; then + echo Installing from official repository + # NOTE || true to continue if no packages have been selected + sudo pacman -S --needed - < "$setupdir/selectedpkgs.txt" || true +fi # install selected aur packages -echo Installing from AUR -# NOTE || true to continue if no packages have been selected -paru -S --needed - < "$setupdir/aurselectedpkgs.txt" || true +if [ -f "$setupdir/aurselectedpkgs.txt" ]; then + echo Installing from AUR + # NOTE || true to continue if no packages have been selected + paru -S --needed - < "$setupdir/aurselectedpkgs.txt" || true +fi : ' if [ $in_vmware15 -eq 1 ]; then