Skip to content

Instantly share code, notes, and snippets.

@jmkim
Created March 22, 2026 16:43
Show Gist options
  • Select an option

  • Save jmkim/2e6b414c389f819f72db9bbe4686a43f to your computer and use it in GitHub Desktop.

Select an option

Save jmkim/2e6b414c389f819f72db9bbe4686a43f to your computer and use it in GitHub Desktop.
Disable wake-up on lid open - https://superuser.com/a/1700733
[Unit]
Description=Disable wake-up on lid open
[Service]
ExecStart=/bin/bash -c '[ "$(cat /proc/acpi/wakeup | grep -oP "LID.*\*\K\w+")" == "enabled" ] && echo "LID" > /proc/acpi/wakeup'
[Install]
WantedBy=multi-user.target
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment