c5b8d04b84
Wall displays must never blank. --noblank applies two layers: an Xorg ServerFlags snippet with all four timeouts at 0 (covers the DM greeter, and survives reboots) and an xset line in the i3 autostart (a session or DM can re-enable the screensaver after X starts). Either alone is insufficient. Documents the trap that cost time here: `sudo xset ...` targets root's X connection and silently does nothing, so a `sudo bash noblank.sh` wrapper looks like it worked while blanking stays fully armed. Also fixes a latent bug: `[ "$relogin" = yes ] && echo ...` as the final statement made install.sh exit non-zero under `set -e` -- and skip the closing instructions -- whenever a relogin was not required. Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
51 lines
1.6 KiB
Bash
Executable File
51 lines
1.6 KiB
Bash
Executable File
#!/bin/sh
|
|
# Remove socktop-swipe. Leaves lisgd, the 'input' group membership and your
|
|
# socktop profiles alone -- those are useful independently and removing them
|
|
# could break other things.
|
|
#
|
|
# ./uninstall.sh remove scripts, config and the X ignore rule
|
|
# ./uninstall.sh --keep-config leave the config file in place
|
|
set -eu
|
|
|
|
PREFIX=${PREFIX:-/usr/local}
|
|
BIN="$PREFIX/bin"
|
|
CONF="$PREFIX/etc/socktop-swipe.env"
|
|
XCONF=/etc/X11/xorg.conf.d/99-ignore-touch-socktop-swipe.conf
|
|
BCONF=/etc/X11/xorg.conf.d/10-no-blanking-socktop-swipe.conf
|
|
|
|
keep_config=no
|
|
[ "${1:-}" = "--keep-config" ] && keep_config=yes
|
|
|
|
# Stop anything running. -x matches the exact process name; -f would also match
|
|
# this script's own command line and kill the shell running it.
|
|
pkill -x lisgd 2>/dev/null || true
|
|
|
|
for f in socktop-rack socktop-swipe socktop-gestures; do
|
|
if [ -e "$BIN/$f" ]; then
|
|
sudo rm -f "$BIN/$f"
|
|
echo "removed $BIN/$f"
|
|
fi
|
|
done
|
|
|
|
if [ "$keep_config" = no ] && [ -e "$CONF" ]; then
|
|
sudo rm -f "$CONF"
|
|
echo "removed $CONF"
|
|
fi
|
|
|
|
if [ -e "$XCONF" ]; then
|
|
sudo rm -f "$XCONF"
|
|
echo "removed $XCONF (touch returns to X after the next X restart)"
|
|
fi
|
|
|
|
if [ -e "$BCONF" ]; then
|
|
sudo rm -f "$BCONF"
|
|
echo "removed $BCONF (screen blanking returns after the next X restart)"
|
|
fi
|
|
|
|
echo
|
|
echo "Left in place on purpose:"
|
|
echo " * lisgd -- remove with: sudo make -C ~/src/lisgd uninstall"
|
|
echo " * 'input' group -- remove with: sudo gpasswd -d $(id -un) input"
|
|
echo " * i3 autostart -- delete the 'socktop-swipe' block in ~/.config/i3/config"
|
|
echo " * socktop profiles -- ~/.config/socktop/profiles.json"
|