Extract pkg cmd abstractions and clean up all migrations (#1291)

* No using custom chromium.desktop any more

* Spacing

* Rely on $OMARCHY_PATH

* Add common pkg and cmd functions for use in migrations and elsewhere

* Simple pkg-adds

* Later migration does it

* Ensure running migrations on older installs have the new pkg/cmds available

* Spacing

* Use new abstractions

* Installed in later migration

* Needless comment

* Use new commands

* Fix package name from 'batt' to 'bat'
This commit is contained in:
David Heinemeier Hansson
2025-08-30 07:41:05 +02:00
committed by GitHub
parent 4f6f92b2cc
commit a3c5e589f6
65 changed files with 132 additions and 153 deletions

View File

@@ -66,3 +66,53 @@ img2png() {
"${1%.*}.png" "${1%.*}.png"
} }
pkg-present() {
for pkg in "$@"; do
pacman -Q "$pkg" &>/dev/null || return 1
done
return 0
}
pkg-missing() {
for pkg in "$@"; do
if ! pacman -Q "$pkg" &>/dev/null; then
return 0
fi
done
return 1
}
pkg-add() {
for pkg in "$@"; do
if ! pacman -Q "$pkg" &>/dev/null; then
sudo pacman -S --noconfirm --needed "$pkg"
fi
done
}
pkg-remove() {
for pkg in "$@"; do
if pacman -Q "$pkg" &>/dev/null; then
sudo pacman -Rns --noconfirm "$pkg"
fi
done
}
cmd-present() {
for cmd in "$@"; do
command -v "$cmd" &>/dev/null || return 1
done
return 0
}
cmd-missing() {
for cmd in "$@"; do
if ! command -v "$cmd" &>/dev/null; then
return 0
fi
done
return 1
}

3
migrations/1751134562.sh Normal file
View File

@@ -0,0 +1,3 @@
echo "Ensure new pkg/cmd functions are available to old-run migrations"
source $OMARCHY_PATH/default/bash/functions

View File

@@ -1,5 +1,3 @@
echo "Add missing installation of bat (used by the ff alias)" echo "Add missing installation of bat (used by the ff alias)"
if ! command -v bat &>/dev/null; then
# Add missing installation of bat pkg-add bat
sudo pacman -S --noconfirm --needed bat
fi

View File

@@ -1,5 +1,3 @@
echo "Installing missing fd terminal tool for finding files" echo "Installing missing fd terminal tool for finding files"
if ! command -v fd &>/dev/null; then pkg-add fd
sudo pacman -S --noconfirm --needed fd
fi

View File

@@ -1,8 +1,9 @@
echo "Switching from vlc to mpv for the default video player" echo "Switching from vlc to mpv for the default video player"
if ! command -v mpv &>/dev/null; then if cmd-missing mpv; then
sudo pacman -Rns --noconfirm vlc pkg-remove vlc
rm ~/.local/share/applications/vlc.desktop rm ~/.local/share/applications/vlc.desktop
sudo pacman -S --noconfirm mpv
pkg-add mpv
xdg-mime default mpv.desktop video/mp4 xdg-mime default mpv.desktop video/mp4
xdg-mime default mpv.desktop video/x-msvideo xdg-mime default mpv.desktop video/x-msvideo
xdg-mime default mpv.desktop video/x-matroska xdg-mime default mpv.desktop video/x-matroska

View File

@@ -1,5 +1,3 @@
echo "Add LocalSend as new default application" echo "Add LocalSend as new default application"
if ! command -v localsend &>/dev/null; then pkg-add localsend
sudo pacman -S --noconfirm --needed localsend
fi

View File

@@ -1,5 +1,3 @@
echo "Install ffmpegthumbnailer for video thumbnails in the file manager" echo "Install ffmpegthumbnailer for video thumbnails in the file manager"
if ! command -v ffmpegthumbnailer &>/dev/null; then pkg-add ffmpegthumbnailer
sudo pacman -S --noconfirm --needed ffmpegthumbnailer
fi

View File

@@ -1,5 +1,3 @@
echo "Install bash-completion" echo "Install bash-completion"
if ! pacman -Q bash-completion &>/dev/null; then pkg-add bash-completion
sudo pacman -S --noconfirm --needed bash-completion
fi

View File

@@ -1,6 +1,6 @@
echo "Install Impala as new wifi selection TUI" echo "Install Impala as new wifi selection TUI"
if ! command -v impala &>/dev/null; then
sudo pacman -S --noconfirm --needed impala if cmd-missing impala; then
echo "You need to update the Waybar config to use Impala Wi-Fi selector in top bar." pkg-add impala
omarchy-refresh-waybar omarchy-refresh-waybar
fi fi

View File

@@ -1,2 +1,3 @@
echo "Permanently fix F-keys on Apple-mode keyboards (like Lofree Flow84)" echo "Permanently fix F-keys on Apple-mode keyboards (like Lofree Flow84)"
source ~/.local/share/omarchy/install/config/hardware/fix-fkeys.sh
source $OMARCHY_PATH/install/config/hardware/fix-fkeys.sh

View File

@@ -1,5 +1,3 @@
echo "Adding gnome-keyring to make 1password work with 2FA codes" echo "Adding gnome-keyring to make 1password work with 2FA codes"
if ! command -v gnome-keyring &>/dev/null; then pkg-add gnome-keyring
sudo pacman -S --noconfirm --needed gnome-keyring
fi

View File

@@ -1,4 +1,4 @@
echo "Install Plymouth splash screen" echo "Install Plymouth splash screen"
sudo pacman -S --needed --noconfirm uwsm plymouth pkg-add uwsm plymouth
source "$HOME/.local/share/omarchy/install/login/plymouth.sh" source "$OMARCHY_PATH/install/login/plymouth.sh"

View File

@@ -1,4 +1,5 @@
echo "Switching to polkit-gnome for better fingerprint authentication compatibility" echo "Switching to polkit-gnome for better fingerprint authentication compatibility"
if ! command -v /usr/lib/polkit-gnome/polkit-gnome-authentication-agent-1 &>/dev/null; then if ! command -v /usr/lib/polkit-gnome/polkit-gnome-authentication-agent-1 &>/dev/null; then
sudo pacman -S --noconfirm --needed polkit-gnome sudo pacman -S --noconfirm --needed polkit-gnome
systemctl --user stop hyprpolkitagent systemctl --user stop hyprpolkitagent

View File

@@ -1,4 +1,5 @@
echo "Migrate to the modular implementation of hyprlock" echo "Migrate to the modular implementation of hyprlock"
if [ -L ~/.config/hypr/hyprlock.conf ]; then if [ -L ~/.config/hypr/hyprlock.conf ]; then
rm ~/.config/hypr/hyprlock.conf rm ~/.config/hypr/hyprlock.conf
cp ~/.local/share/omarchy/config/hypr/hyprlock.conf ~/.config/hypr/hyprlock.conf cp ~/.local/share/omarchy/config/hypr/hyprlock.conf ~/.config/hypr/hyprlock.conf

View File

@@ -1,7 +1,5 @@
echo "Update chromium.desktop to ensure we are always using wayland" echo "Update chromium.desktop to ensure we are always using wayland"
if [[ ! -f ~/.local/share/applications/chromium.desktop ]]; then
cp ~/.local/share/omarchy/applications/chromium.desktop ~/.local/share/applications/ xdg-settings set default-web-browser chromium.desktop
xdg-settings set default-web-browser chromium.desktop xdg-mime default chromium.desktop x-scheme-handler/http
xdg-mime default chromium.desktop x-scheme-handler/http xdg-mime default chromium.desktop x-scheme-handler/https
xdg-mime default chromium.desktop x-scheme-handler/https
fi

View File

@@ -1,4 +1,5 @@
echo "Migrate to the modular, variable-based implementation of waybar style.css" echo "Migrate to the modular, variable-based implementation of waybar style.css"
if [ -L ~/.config/waybar/style.css ]; then if [ -L ~/.config/waybar/style.css ]; then
rm ~/.config/waybar/style.css rm ~/.config/waybar/style.css
cp ~/.local/share/omarchy/config/waybar/style.css ~/.config/waybar/style.css cp ~/.local/share/omarchy/config/waybar/style.css ~/.config/waybar/style.css

View File

@@ -1,5 +1,6 @@
echo "Update to use UWSM and seamless login" echo "Update to use UWSM and seamless login"
if ! command -v uwsm &>/dev/null; then
if cmd-missing uwsm; then
sudo rm -f /etc/systemd/system/getty@tty1.service.d/override.conf sudo rm -f /etc/systemd/system/getty@tty1.service.d/override.conf
sudo rmdir /etc/systemd/system/getty@tty1.service.d/ 2>/dev/null || true sudo rmdir /etc/systemd/system/getty@tty1.service.d/ 2>/dev/null || true
@@ -14,5 +15,5 @@ if ! command -v uwsm &>/dev/null; then
sed -i 's/^GTK_IM_MODULE=fcitx$//' "$HOME/.config/environment.d/fcitx.conf" sed -i 's/^GTK_IM_MODULE=fcitx$//' "$HOME/.config/environment.d/fcitx.conf"
fi fi
source ~/.local/share/omarchy/install/login/plymouth.sh source $OMARCHY_PATH/install/login/plymouth.sh
fi fi

View File

@@ -1,3 +1,4 @@
echo "Add color and animation to pacman installs" echo "Add color and animation to pacman installs"
grep -q '^Color' /etc/pacman.conf || sudo sed -i '/^\[options\]/a Color' /etc/pacman.conf grep -q '^Color' /etc/pacman.conf || sudo sed -i '/^\[options\]/a Color' /etc/pacman.conf
grep -q '^ILoveCandy' /etc/pacman.conf || sudo sed -i '/^\[options\]/a ILoveCandy' /etc/pacman.conf grep -q '^ILoveCandy' /etc/pacman.conf || sudo sed -i '/^\[options\]/a ILoveCandy' /etc/pacman.conf

View File

@@ -1,5 +1,3 @@
echo "Install missing docker-buildx package for out-of-the-box Kamal compatibility" echo "Install missing docker-buildx package for out-of-the-box Kamal compatibility"
if ! docker buildx version &>/dev/null; then pkg-add docker-buildx
sudo pacman -S --noconfirm --needed docker-buildx
fi

View File

@@ -1,4 +1,5 @@
echo "Make light themes possible" echo "Make light themes possible"
if [[ -f ~/.local/share/applications/blueberry.desktop ]]; then if [[ -f ~/.local/share/applications/blueberry.desktop ]]; then
rm -f ~/.local/share/applications/blueberry.desktop rm -f ~/.local/share/applications/blueberry.desktop
rm -f ~/.local/share/applications/org.pulseaudio.pavucontrol.desktop rm -f ~/.local/share/applications/org.pulseaudio.pavucontrol.desktop

View File

@@ -1,4 +1,5 @@
echo "Rename waybar config file for syntax highlighting" echo "Rename waybar config file for syntax highlighting"
if [[ -f ~/.config/waybar/config ]]; then if [[ -f ~/.config/waybar/config ]]; then
mv ~/.config/waybar/config ~/.config/waybar/config.jsonc mv ~/.config/waybar/config ~/.config/waybar/config.jsonc
fi fi

View File

@@ -1,4 +1,5 @@
echo "Prevent docker from requiring network readiness on boot" echo "Prevent docker from requiring network readiness on boot"
if [[ ! -f /etc/systemd/system/docker.service.d/no-block-boot.conf ]]; then if [[ ! -f /etc/systemd/system/docker.service.d/no-block-boot.conf ]]; then
sudo mkdir -p /etc/systemd/system/docker.service.d/ sudo mkdir -p /etc/systemd/system/docker.service.d/
sudo tee /etc/systemd/system/docker.service.d/no-block-boot.conf <<'EOF' sudo tee /etc/systemd/system/docker.service.d/no-block-boot.conf <<'EOF'

View File

@@ -1,4 +1,5 @@
echo "Add Catppuccin Latte light theme" echo "Add Catppuccin Latte light theme"
if [[ ! -L "~/.config/omarchy/themes/catppuccin-latte" ]]; then if [[ ! -L "~/.config/omarchy/themes/catppuccin-latte" ]]; then
ln -snf ~/.local/share/omarchy/themes/catppuccin-latte ~/.config/omarchy/themes/ ln -snf ~/.local/share/omarchy/themes/catppuccin-latte ~/.config/omarchy/themes/
fi fi

View File

@@ -1,5 +1,3 @@
echo "Install slurp + wl-screenrec for new ALT+PrintScreen screen recorder" echo "Install slurp + wl-screenrec for new ALT+PrintScreen screen recorder"
if ! command -v wl-screenrec &>/dev/null || ! command -v slurp &>/dev/null; then pkg-add slurp wl-screenrec
sudo pacman -S --noconfirm --needed slurp wl-screenrec
fi

View File

@@ -1,9 +1,8 @@
echo "Replace volume control GUI with a TUI" echo "Replace volume control GUI with a TUI"
if ! command -v wiremix &>/dev/null; then if cmd-missing wiremix; then
sudo pacman -S --noconfirm --needed wiremix pkg-add wiremix
sudo pacman -Rns --noconfirm pavucontrol pkg-remove pavucontrol
omarchy-refresh-applications omarchy-refresh-applications
omarchy-refresh-waybar omarchy-refresh-waybar
fi fi

View File

@@ -1,4 +1,3 @@
echo "Remove needless fcitx5-configtool package" echo "Remove needless fcitx5-configtool package"
if pacman -Qe fcitx5-configtool &>/dev/null; then
sudo pacman -Rns --noconfirm fcitx5-configtool pkg-remove fcitx5-configtool
fi

View File

@@ -1,2 +1,3 @@
echo "Update .config/hypr/hyprlock.conf to include failed attempt counter" echo "Update .config/hypr/hyprlock.conf to include failed attempt counter"
omarchy-refresh-hyprlock omarchy-refresh-hyprlock

View File

@@ -1,5 +1,3 @@
echo "Install satty for the new screenshot flow" echo "Install satty for the new screenshot flow"
if ! command -v satty &>/dev/null; then pkg-add satty
sudo pacman -S --noconfirm --needed satty
fi

View File

@@ -1,9 +1,9 @@
echo "Replace wofi with walker as the default launcher" echo "Replace wofi with walker as the default launcher"
if ! command -v walker &>/dev/null; then if cmd-missing walker; then
sudo pacman -S --noconfirm --needed walker-bin libqalculate pkg-add walker-bin libqalculate
sudo pacman -Rns --noconfirm wofi pkg-remove wofi
rm -rf ~/.config/wofi rm -rf ~/.config/wofi
mkdir -p ~/.config/walker mkdir -p ~/.config/walker

View File

@@ -1,6 +1,6 @@
echo "Install swayOSD to show volume status" echo "Install swayOSD to show volume status"
if ! command -v swayosd-server &>/dev/null; then if cmd-missing swayosd-server; then
sudo pacman -S --noconfirm --needed swayosd pkg-add swayosd
setsid uwsm app -- swayosd-server &>/dev/null & setsid uwsm app -- swayosd-server &>/dev/null &
fi fi

View File

@@ -1,7 +1,3 @@
echo "Install wf-recorder for screen recording for nvidia" echo "Install wf-recorder for screen recording for nvidia"
if lspci | grep -qi 'nvidia'; then pkg-add wf-recorder
if ! command -v wf-recorder &>/dev/null; then
sudo pacman -S --noconfirm --needed wf-recorder
fi
fi

View File

@@ -1,5 +0,0 @@
echo "Add Terminal Text Effects for rizzing Omarchy"
if ! pacman -Q python-terminaltexteffects &>/dev/null; then
sudo pacman -S --noconfirm python-terminaltexteffects
fi

View File

@@ -1,5 +1,6 @@
echo "Allow updating of timezone by right-clicking on the clock (or running omarchy-cmd-tzupdate)" echo "Allow updating of timezone by right-clicking on the clock (or running omarchy-cmd-tzupdate)"
if ! command -v tzupdate &>/dev/null; then
bash ~/.local/share/omarchy/install/config/timezones.sh if cmd-missing tzupdate; then
$OMARCHY_PATH/install/config/timezones.sh
omarchy-refresh-waybar omarchy-refresh-waybar
fi fi

View File

@@ -1,4 +0,0 @@
echo "Update Walker config to include = as the leader key for the calculator"
if ! grep -q 'prefix = "="' ~/.config/walker/config.toml; then
omarchy-refresh-walker
fi

View File

@@ -1,4 +0,0 @@
echo "Update Walker config to include . as the leader key for the finder"
if ! grep -q 'prefix = "\."' ~/.config/walker/config.toml; then
omarchy-refresh-walker
fi

View File

@@ -1,5 +0,0 @@
echo "Ensure screensaver doesn't start while the computer is locked"
if ! grep -q "pidof hyprlock || omarchy-launch-screensaver" ~/.config/hypr/hypridle.conf; then
omarchy-refresh-hypridle
fi

View File

@@ -1,5 +0,0 @@
echo "Update app launcher config to allow enough entries to show all keybindings on SUPER+K"
if ! grep "max_entries = 200" ~/.config/walker/config.toml; then
omarchy-refresh-walker
fi

View File

@@ -1,7 +1,7 @@
echo "Enable auto-discovery of network printers" echo "Enable auto-discovery of network printers"
if [[ ! -f /etc/systemd/resolved.conf.d/10-disable-multicast.conf ]]; then if [[ ! -f /etc/systemd/resolved.conf.d/10-disable-multicast.conf ]]; then
sudo pacman -S --noconfirm avahi nss-mdns pkg-add avahi nss-mdns
# Disable multicast dns in resolved. Avahi will provide this for better network printer discovery # Disable multicast dns in resolved. Avahi will provide this for better network printer discovery
sudo mkdir -p /etc/systemd/resolved.conf.d sudo mkdir -p /etc/systemd/resolved.conf.d
@@ -10,7 +10,7 @@ if [[ ! -f /etc/systemd/resolved.conf.d/10-disable-multicast.conf ]]; then
fi fi
if ! grep -q '^CreateRemotePrinters Yes' /etc/cups/cups-browsed.conf; then if ! grep -q '^CreateRemotePrinters Yes' /etc/cups/cups-browsed.conf; then
sudo pacman -S --noconfirm cups-browsed pkg-add cups-browsed
# Enable automatically adding remote printers # Enable automatically adding remote printers
echo 'CreateRemotePrinters Yes' | sudo tee -a /etc/cups/cups-browsed.conf echo 'CreateRemotePrinters Yes' | sudo tee -a /etc/cups/cups-browsed.conf
sudo systemctl enable --now cups-browsed.service sudo systemctl enable --now cups-browsed.service

View File

@@ -1,2 +1,3 @@
echo "Add support for accessing Android phone data via file manager" echo "Add support for accessing Android phone data via file manager"
sudo pacman -S --noconfirm --needed gvfs-mtp
pkg-add gvfs-mtp

View File

@@ -1,2 +0,0 @@
echo "Increase time before screensaver starts to 2.5 minutes (from 1 minute)"
omarchy-refresh-hypridle

View File

@@ -1,2 +1,3 @@
echo "Add chromium-flags.conf" echo "Add chromium-flags.conf"
omarchy-refresh-config chromium-flags.conf omarchy-refresh-config chromium-flags.conf

View File

@@ -1,4 +1,5 @@
echo "Change update-available icon in top bar from  to " echo "Change update-available icon in top bar from  to "
if grep -q '"format": "",' ~/.config/waybar/config.jsonc; then if grep -q '"format": "",' ~/.config/waybar/config.jsonc; then
sed -i 's/"format": ""/"format": ""/' ~/.config/waybar/config.jsonc sed -i 's/"format": ""/"format": ""/' ~/.config/waybar/config.jsonc
fi fi

View File

@@ -1,2 +0,0 @@
echo "Restart Walker to pick up menu selections"
omarchy-restart-walker

View File

@@ -1,2 +1,3 @@
echo "Remove old Omarchy TUI app now that we have the Omarchy Menu" echo "Remove old Omarchy TUI app now that we have the Omarchy Menu"
rm -rf ~/.local/share/applications/omarchy.desktop
rm -f ~/.local/share/applications/omarchy.desktop

View File

@@ -1,3 +1,3 @@
echo "Add xmlstarlet needed for updating fonts via Omarchy menu" echo "Add xmlstarlet needed for updating fonts via Omarchy menu"
sudo pacman -S --noconfirm --needed xmlstarlet pkg-add xmlstarlet

View File

@@ -1,3 +0,0 @@
echo "Update OS icon in About from Windows to Arch"
omarchy-refresh-config fastfetch/config.jsonc

View File

@@ -1,4 +1,3 @@
echo "Tune MTU probing for more reliable SSH" echo "Tune MTU probing for more reliable SSH"
# Solve common flakiness with SSH
echo "net.ipv4.tcp_mtu_probing=1" | sudo tee -a /etc/sysctl.d/99-sysctl.conf echo "net.ipv4.tcp_mtu_probing=1" | sudo tee -a /etc/sysctl.d/99-sysctl.conf

View File

@@ -1,5 +0,0 @@
echo "Lock 1password on screen lock"
if ! grep -q "omarchy-lock-screen" ~/.config/hypr/hypridle.conf; then
omarchy-refresh-hypridle
fi

View File

@@ -1,2 +0,0 @@
echo "Update Walker config"
omarchy-refresh-walker

View File

@@ -1,4 +1,5 @@
echo "Update polkit policy to yield to fingerprint and fido2" echo "Update polkit policy to yield to fingerprint and fido2"
# If fprint exists in polkit, it was wrong and needs reset # If fprint exists in polkit, it was wrong and needs reset
if [ -f /etc/pam.d/polkit-1 ] && grep -Fq 'pam_fprintd.so' /etc/pam.d/polkit-1; then if [ -f /etc/pam.d/polkit-1 ] && grep -Fq 'pam_fprintd.so' /etc/pam.d/polkit-1; then
sudo tee /etc/pam.d/polkit-1 >/dev/null <<'EOF' sudo tee /etc/pam.d/polkit-1 >/dev/null <<'EOF'

View File

@@ -1,4 +1,5 @@
echo "Add start burst limit to login" echo "Add start burst limit to login"
if [ -f /etc/systemd/system/omarchy-seamless-login.service ]; then if [ -f /etc/systemd/system/omarchy-seamless-login.service ]; then
cat <<EOF | sudo tee /etc/systemd/system/omarchy-seamless-login.service cat <<EOF | sudo tee /etc/systemd/system/omarchy-seamless-login.service
[Unit] [Unit]

View File

@@ -1,2 +1,3 @@
echo "Update Walker config to add 60s timeout such that it won't conflict with screensaver" echo "Update Walker config to add 60s timeout such that it won't conflict with screensaver"
omarchy-refresh-walker omarchy-refresh-walker

View File

@@ -9,9 +9,9 @@ set_theme_colors() {
fi fi
} }
if command -v chromium &>/dev/null; then if cmd-present chromium; then
sudo pacman -Rns --noconfirm chromium || true pkg-remove chromium
sudo pacman -S --noconfirm omarchy-chromium pkg-add omarchy-chromium
if pgrep -x chromium; then if pgrep -x chromium; then
if gum confirm "Chromium must be restarted. Ready?"; then if gum confirm "Chromium must be restarted. Ready?"; then

View File

@@ -1,6 +1,6 @@
echo "Add minimal starship prompt to terminal" echo "Add minimal starship prompt to terminal"
if ! command -v starship &>/dev/null; then if cmd-missing starship; then
sudo pacman -S --noconfirm starship pkg-add starship
cp $OMARCHY_PATH/config/starship.toml ~/.config/starship.toml cp $OMARCHY_PATH/config/starship.toml ~/.config/starship.toml
fi fi

View File

@@ -1,9 +1,3 @@
echo "Ensure TTE and dependencies are installed" echo "Ensure TTE and dependencies are installed"
if ! pacman -Q python-poetry-core &>/dev/null; then pkg-add python-poetry-core python-terminaltexteffects
sudo pacman -S --noconfirm python-poetry-core
fi
if ! pacman -Q python-terminaltexteffects &>/dev/null; then
sudo pacman -S --noconfirm python-terminaltexteffects
fi

View File

@@ -1,5 +1,3 @@
echo "Add potentially missing dependency for power profile controls" echo "Add potentially missing dependency for power profile controls"
if ! pacman -Q python-gobject &>/dev/null; then pkg-add python-gobject
sudo pacman -S --noconfirm python-gobject
fi

View File

@@ -1,3 +0,0 @@
echo "Update fastfetch config to include current theme name and colors"
omarchy-refresh-config fastfetch/config.jsonc

View File

@@ -1,3 +0,0 @@
echo "Turn on the screensaver by default again now that TTE has been fixed"
omarchy-refresh-hypridle

View File

@@ -1,5 +1,3 @@
echo "Install wf-recorder for intel based device" echo "Install wf-recorder for intel based device"
if lspci | grep -Eqi 'nvidia|intel.*graphics'; then pkg-add wf-recorder
sudo pacman -S --noconfirm --needed wf-recorder
fi

View File

@@ -1,6 +1,4 @@
echo "Switch from lazydocker-bin to lazydocker official" echo "Switch from lazydocker-bin to lazydocker official"
if pacman -Q lazydocker-bin >/dev/null; then pkg-remove lazydocker-bin
sudo pacman -Rns --noconfirm lazydocker-bin pkg-add lazydocker
sudo pacman -S --noconfirm lazydocker
fi

View File

@@ -1,15 +1,13 @@
echo "Migrate AUR packages to official repos where possible" echo "Migrate AUR packages to official repos where possible"
reinstall_package_opr() { reinstall_package_opr() {
if pacman -Q $1 >/dev/null; then if pkg-present $1; then
sudo pacman -Rns --noconfirm $1 sudo pacman -Rns --noconfirm $1
sudo pacman -S --noconfirm ${2:-$1} sudo pacman -S --noconfirm ${2:-$1}
fi fi
} }
if pacman -Q yay-bin-debug >/dev/null; then pkg-remove yay-bin-debug
sudo pacman -Rns --noconfirm yay-bin-debug
fi
reinstall_package_opr yay-bin yay reinstall_package_opr yay-bin yay
reinstall_package_opr obsidian-bin obsidian reinstall_package_opr obsidian-bin obsidian

View File

@@ -1,2 +0,0 @@
echo "Update Hypridle to prevent flash of unlocked screen after sleep"
omarchy-refresh-hypridle

View File

@@ -1,6 +1,6 @@
echo "Replace buggy native Zoom client with webapp" echo "Replace buggy native Zoom client with webapp"
if pacman -Q zoom >/dev/null; then if pkg-present zoom; then
sudo pacman -Rns --noconfirm zoom pkg-remove zoom
omarchy-webapp-install "Zoom" https://app.zoom.us/wc/home https://cdn.jsdelivr.net/gh/homarr-labs/dashboard-icons/png/zoom.png omarchy-webapp-install "Zoom" https://app.zoom.us/wc/home https://cdn.jsdelivr.net/gh/homarr-labs/dashboard-icons/png/zoom.png
fi fi

View File

@@ -1,12 +1,6 @@
echo "Remove any Chaotic-AUR infrastructure packages" echo "Remove any Chaotic-AUR infrastructure packages"
if pacman -Q chaotic-keyring 2>/dev/null; then pkg-remove chaotic-keyring chaotic-mirrorlist
sudo pacman -Rns --noconfirm chaotic-keyring
fi
if pacman -Q chaotic-mirrorlist 2>/dev/null; then
sudo pacman -Rns --noconfirm chaotic-mirrorlist
fi
if sudo pacman-key --list-keys 3056513887B78AEB >/dev/null 2>&1; then if sudo pacman-key --list-keys 3056513887B78AEB >/dev/null 2>&1; then
sudo pacman-key --delete 3056513887B78AEB sudo pacman-key --delete 3056513887B78AEB

View File

@@ -1,5 +1,3 @@
echo "Add back ttf-ia-writer if it was missing" echo "Add back ttf-ia-writer if it was missing"
if ! pacman -Q ttf-ia-writer 2>/dev/null; then pkg-add ttf-ia-writer
sudo pacman -S --noconfirm ttf-ia-writer
fi