Last active
July 30, 2025 08:15
-
-
Save cmbuckley/c0c39559c2e052c8b218007d0f6aa2a7 to your computer and use it in GitHub Desktop.
Natural scrolling on a trackpad, but classic scrolling when a mouse is plugged in
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/bin/bash | |
| # flip scroll direction based on whether a mouse is plugged in | |
| defaults write -g com.apple.swipescrolldirection -bool $(ioreg -p IOUSB -w0 | grep -q Mouse && echo false || echo true) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment