- bin/omarchy-wifi-powersave: shopt -s nullglob. Previously, machines
with no wireless interfaces ran the loop once with the literal glob
('iface=*'), failed iw, and exited 237. With the new always-installed
udev rule that invokes this on every AC transition, the failure
would surface as failed transient omarchy-wifi-powersave-* units on
desktops. Now it cleanly no-ops.
- migrations/1779307845.sh: add 'systemctl daemon-reload' so the
plocate-updatedb.service.d/ac-only.conf drop-in is picked up on
upgrade. Arch's systemd pacman hook only triggers on
/usr/lib/systemd/system/*, not /etc/systemd/system/*.
- install/config/powerprofilesctl-rules.sh and wifi-powersave-rules.sh:
rm -f the pre-rename legacy paths before udevadm reload, so the
cleanup is idempotent outside the one-shot migration (matters for
re-install/downgrade testing).
20 lines
976 B
Bash
20 lines
976 B
Bash
echo "Clean up legacy udev rules now namespaced under 99-omarchy-*.rules"
|
|
|
|
# powerprofilesctl-rules.sh used to write /etc/udev/rules.d/99-power-profile.rules.
|
|
# Package now ships /etc/udev/rules.d/99-omarchy-power-profile.rules. Both
|
|
# rules would fire simultaneously, so remove the old one.
|
|
sudo rm -f /etc/udev/rules.d/99-power-profile.rules
|
|
|
|
# wifi-powersave-rules.sh used to write /etc/udev/rules.d/99-wifi-powersave.rules.
|
|
# Package now ships /etc/udev/rules.d/99-omarchy-wifi-powersave.rules. Same.
|
|
sudo rm -f /etc/udev/rules.d/99-wifi-powersave.rules
|
|
|
|
# Reload so the new udev rules take effect immediately.
|
|
sudo udevadm control --reload 2>/dev/null
|
|
sudo udevadm trigger --subsystem-match=power_supply 2>/dev/null
|
|
|
|
# The plocate-updatedb.service drop-in is installed under /etc/systemd/system,
|
|
# which Arch's systemd pacman hook does NOT trigger on. Explicitly reload so
|
|
# upgrades pick up the drop-in without needing a reboot.
|
|
sudo systemctl daemon-reload 2>/dev/null
|