From 7ca22bca0127f7bf4b9b813a401e09a90c8e11e3 Mon Sep 17 00:00:00 2001 From: Dan Date: Sat, 5 Feb 2022 14:43:39 +1300 Subject: [PATCH] added aurhelper check for pacman.conf aur-repo --- scripts/server.sh | 11 ++++++++--- 1 file changed, 8 insertions(+), 3 deletions(-) diff --git a/scripts/server.sh b/scripts/server.sh index 4e7fb91..e107669 100644 --- a/scripts/server.sh +++ b/scripts/server.sh @@ -60,7 +60,12 @@ secrets file = /etc/rsyncd.secrets systemctl enable --now rsyncd.service # Add repository to pacman.conf +if AURHELPER=$(pacman -Qmq | grep -E 'yay|pikaur|paru|trizen') ; then + echo "[homerepo-aur] + Server = http://$server:8080/archlinux/\$arch/aur + SigLevel = Never" >> /etc/pacman.conf +else + echo "No AUR helper installed.">&2 +fi echo "[homerepo] -Server = http://$server:8080/archlinux/\$arch" >> /etc/pacman.conf -echo "[homerepo-aur] -Server = http://$server:8080/archlinux/\$arch/aur" >> /etc/pacman.conf \ No newline at end of file +Server = http://$server:8080/archlinux/\$arch" >> /etc/pacman.conf \ No newline at end of file