From c4f93787d62fe9cda652576cd5fab75e182f81d1 Mon Sep 17 00:00:00 2001 From: Jon Kinney Date: Mon, 20 Oct 2025 08:55:28 -0500 Subject: [PATCH] Error fallback if terminal was not installed successfully (#2611) --- bin/omarchy-install-terminal | 18 ++++++++++-------- 1 file changed, 10 insertions(+), 8 deletions(-) diff --git a/bin/omarchy-install-terminal b/bin/omarchy-install-terminal index fbb0c0b3..804ccb7a 100755 --- a/bin/omarchy-install-terminal +++ b/bin/omarchy-install-terminal @@ -8,12 +8,14 @@ fi package="$1" # Install package -omarchy-pkg-add $package +if omarchy-pkg-add $package; then + # Set as default terminal + echo "Setting $package as new default terminal..." + sed -i "/export TERMINAL=/ c\export TERMINAL=$package" ~/.config/uwsm/default -# Set as default terminal -echo "Setting $package as new default terminal..." -sed -i "/export TERMINAL=/ c\export TERMINAL=$package" ~/.config/uwsm/default - -# Restart is needed for new default to take effect -echo -gum confirm "Restart to use new terminal?" && systemctl reboot --no-wall + # Restart is needed for new default to take effect + echo + gum confirm "Restart to use new terminal?" && systemctl reboot --no-wall +else + echo "Failed to install $package" +fi