Skip to content

Instantly share code, notes, and snippets.

@h0tw1r3
Created January 22, 2023 19:33
Show Gist options
  • Star 1 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save h0tw1r3/e4b4c4032547d773ab7f7f1cc6995bf1 to your computer and use it in GitHub Desktop.
Save h0tw1r3/e4b4c4032547d773ab7f7f1cc6995bf1 to your computer and use it in GitHub Desktop.
Linux on Lenovo Thinkpad S1 Yoga
#!/bin/sh
# trackpad and trackpoint are connected to the ps port
# psmouse is not hotplug friendly
# must be removed before sleep
# place this file in /lib/systemd/system-sleep
# and chmod +x
PATH=/sbin:/usr/sbin:/bin:/usr/bin
case $1/$2 in
pre/*)
echo "Going to $2..."
modprobe -r psmouse
;;
post/*)
echo "Waking up from $2..."
sleep 2
modprobe psmouse
;;
esac
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment