From daf45665c4de82403aab40a02c2a3656737314a0 Mon Sep 17 00:00:00 2001 From: Luiz Felipe Machado <56140722+luizfelmach@users.noreply.github.com> Date: Sat, 14 Jun 2025 18:19:33 -0300 Subject: [PATCH] fix(scripts): update flatpak only if command exists (#1000) * fix(scripts): update flatpak only if command exists Add a check to run flatpak update only when the flatpak command is available, since Flatpak is not installed by default on Arch Linux, preventing errors if flatpak is missing. * Update scripts/runUpdates.sh --------- Co-authored-by: Jas Singh --- scripts/runUpdates.sh | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/scripts/runUpdates.sh b/scripts/runUpdates.sh index d090514..9abdff9 100755 --- a/scripts/runUpdates.sh +++ b/scripts/runUpdates.sh @@ -13,8 +13,10 @@ install_arch_updates() { else echo "Missing AUR Helper. Try installing yay or paru" fi - echo "Updating Flatpak packages..." - flatpak update -y + if command -v flatpak &> /dev/null; then + echo "Updating Flatpak packages..." + flatpak update -y + fi echo "Done with Arch & AUR updates." }