Skip to content

Instantly share code, notes, and snippets.

View stefanmm's full-sized avatar
🏠
Working from home

Stefan stefanmm

🏠
Working from home
View GitHub Profile
@stefanmm
stefanmm / usb_reset.sh
Last active June 28, 2024 13:33 — forked from erwin/turn-off-device.sh
Fix: USB keyboard not working in Linux after sleep/suspend
#!/bin/bash
# Thanks to:
# https://gist.github.com/erwin/a66a4c3f8a5d940ab6c434b48568ff39
# https://bbs.archlinux.org/viewtopic.php?pid=1956897#p1956897
# HOW TO:
# 1) Copy this file to /usr/local/bin/usb_reset.sh
# 2) make it executable: sudo chmod +x /usr/local/bin/usb_reset.sh
# 3) Create new service: sudo nano /etc/systemd/system/usb_reset.service