Update installAurDeps()

This commit is contained in:
Santiago Lo Coco 2022-03-01 11:50:52 -03:00
parent 0fe663c71e
commit 26ee1d4f7b
1 changed files with 7 additions and 1 deletions

View File

@ -14,7 +14,13 @@ installAurDeps() {
sudo -u nobody makepkg --printsrcinfo > .SRCINFO sudo -u nobody makepkg --printsrcinfo > .SRCINFO
regExp="^[[:space:]]*\(make\)\?depends\(.\)* = \([[:alnum:][:punct:]]*\)[[:space:]]*$" regExp="^[[:space:]]*\(make\)\?depends\(.\)* = \([[:alnum:][:punct:]]*\)[[:space:]]*$"
mapfile -t pkgDeps < <(sed -n -e "s/$regExp/\3/p" .SRCINFO) 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 rm -rf paru-bin .SRCINFO
fi fi
} }