From 26ee1d4f7b438c7ef2cf39e08fec1c45acbfe988 Mon Sep 17 00:00:00 2001 From: Santiago Lo Coco Date: Tue, 1 Mar 2022 11:50:52 -0300 Subject: [PATCH] Update installAurDeps() --- pkgbuild.sh | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/pkgbuild.sh b/pkgbuild.sh index 2b90e9c..77eca8a 100755 --- a/pkgbuild.sh +++ b/pkgbuild.sh @@ -14,7 +14,13 @@ installAurDeps() { sudo -u nobody makepkg --printsrcinfo > .SRCINFO regExp="^[[:space:]]*\(make\)\?depends\(.\)* = \([[:alnum:][:punct:]]*\)[[:space:]]*$" mapfile -t pkgDeps < <(sed -n -e "s/$regExp/\3/p" .SRCINFO) - paru -S --noconfirm "${pkgDeps[@]}" + for pkgDep in "${pkgDeps[@]}"; do + pkgName=$(echo "$pkgDep" | sed 's/[><=].*//') + paruOutput=$(paru -Ss "${pkgDep}" | grep "\/${pkgDep} ") + if echo $paruOutput | grep -q "^aur\/" + paru -S --noconfirm "$pkgDep" + fi + done rm -rf paru-bin .SRCINFO fi }