Upgrading systemd runs its post_upgrade scriptlet mid-transaction, which reexecs both the system manager and every user manager. When pacman runs inside a user-session scope (the floating update terminal), that reexec can SIGKILL it and abandon the transaction halfway, with packages upgraded but none of the post-transaction hooks run. Route every Omarchy-owned system mutation through a new hidden omarchy-update-pacman helper that registers the transaction as a PID 1 scope via systemd-run, keeping it out of the user manager's cgroups. System scopes survive the system manager's own reexec, and as a bonus the transaction now also survives its terminal window closing. On unbooted systems (the installer chroot) the helper runs pacman directly. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
19 lines
603 B
Bash
Executable File
19 lines
603 B
Bash
Executable File
#!/bin/bash
|
|
|
|
# omarchy:summary=Reinstall all default Omarchy packages from the stable channel
|
|
# omarchy:requires-sudo=true
|
|
|
|
set -e
|
|
|
|
# Reinstall all default Omarchy packages from the stable channel and downgrade any packages that are too new.
|
|
|
|
# Set the package repository to the stable mirrors
|
|
omarchy-refresh-pacman
|
|
|
|
# Downgrade any packages to the stable setup
|
|
omarchy-update-pacman -Suu --noconfirm
|
|
|
|
# Ensure all packages are installed
|
|
mapfile -t packages < <(grep -v '^#' "$OMARCHY_PATH/install/omarchy-base.packages" | grep -v '^$')
|
|
omarchy-update-pacman -Syu --noconfirm --needed "${packages[@]}"
|