diff --git a/bin/omarchy-update b/bin/omarchy-update index 76fb755b..a9b2ba8d 100755 --- a/bin/omarchy-update +++ b/bin/omarchy-update @@ -2,6 +2,13 @@ set -e +# Run the update inside a PTY so pacman/yay keep showing download progress +# while still logging the full session for later analysis. +if [[ -z $OMARCHY_UPDATE_LOGGED ]]; then + script_command=$(printf '%q ' "$0" "$@") + exec env OMARCHY_UPDATE_LOGGED=1 script -qefc "$script_command" "/tmp/omarchy-update.log" +fi + trap 'echo ""; echo -e "\033[0;31mSomething went wrong during the update!\n\nPlease review the output above carefully, correct the error, and retry the update.\n\nIf you need assistance, get help from the community at https://omarchy.org/discord\033[0m"' ERR if [[ $1 == "-y" ]] || omarchy-update-confirm; then diff --git a/bin/omarchy-update-perform b/bin/omarchy-update-perform index 8965c0c2..d98b96c3 100755 --- a/bin/omarchy-update-perform +++ b/bin/omarchy-update-perform @@ -2,13 +2,6 @@ set -e -# Run the update inside a PTY so pacman/yay keep showing download progress -# while still logging the full session for later analysis. -if [[ -z $OMARCHY_UPDATE_LOGGED ]]; then - script_command=$(printf '%q ' "$0" "$@") - exec env OMARCHY_UPDATE_LOGGED=1 script -qefc "$script_command" "/tmp/omarchy-update.log" -fi - # Ensure screensaver/sleep doesn't set in during updates hyprctl dispatch tagwindow +noidle &>/dev/null || true