From 38d99616222b91eea0ef73a6ee950b46838f10fe Mon Sep 17 00:00:00 2001 From: David Heinemeier Hansson Date: Sun, 24 Aug 2025 17:25:45 +0200 Subject: [PATCH] Install AUR packages if its available --- install/apps/aur.sh | 32 +++++++++++++++++++++----------- 1 file changed, 21 insertions(+), 11 deletions(-) diff --git a/install/apps/aur.sh b/install/apps/aur.sh index de5af366..bfb33887 100644 --- a/install/apps/aur.sh +++ b/install/apps/aur.sh @@ -1,14 +1,24 @@ #!/bin/bash -if [ -z "$OMARCHY_BARE" ]; then - yay -S --noconfirm --needed \ - 1password-beta 1password-clia \ - python-poetry-core python-terminaltexteffects \ - tzupdate wl-screenrec \ - typora ttf-ia-writer -fi +if curl -sf --connect-timeout 30 -A "omarchy-update" \ + "https://aur.archlinux.org/rpc/?v=5&type=info&arg=base" | + jq -e '.type=="multiinfo"' >/dev/null; then + if [ -z "$OMARCHY_BARE" ]; then + yay -S --noconfirm --needed \ + 1password-beta 1password-cli \ + typora ttf-ia-writer + fi -# We install chromium to be safe that we have a browser, -# but replace it with our version if AUR is available -sudo pacman -Rns chromium -yay -S --noconfirm omarchy-chromium-bin + yay -S --noconfirm --needed \ + tzupdate wl-screenrec \ + python-poetry-core python-terminaltexteffects + + # We install chromium to be safe that we have a browser, + # but replace it with our version if AUR is available + sudo pacman -Rns chromium + yay -S --noconfirm omarchy-chromium-bin +else + echo -e "\n\e[31mAUR is unavailable. Skipping installation of: 1password, Typora, tte, tzupdate !\e[0m" + echo "You will have to install these later when AUR is available." + sleep 5 +fi