Warning
this only works on a mac, and probably a very specific version of it. not sure. works on mine though :)
a script that reverses your scroll direction of your mouse if a mouse is connected (wired / bluetooth/ 2.4g / whatever) while keeping your trackpad's scroll direction "correct" / "natural" / whatever.
whenever i plug in my laptop (mac os) to a dock, the mouse scroll direction is the opposite of what i want. so i go change it in the settings. but when i unplug from the dock to code in bed (which means no mouse), my trackpad scrolls the wrong way and now i have to go back to the settings and change it back.
"why spend 5 minutes doing something manually when you can spend 5 hours automating it?"
other languages calls these C stuff anyway when trying to control a mac's settings (i think), so why not just do it in C. AND ALSO... WHY NOT LUL
brew install narasaka/tap/adaptive-scroll
brew services start adaptive-scroll
Important
running the commands above will prompt you to give it the permissions that the script needs.
but if somehow the prompt did not happen, give it permission by going to
System Settings -> Privacy & Security -> Accessibility
and turning the switch for adaptive-scroll on
- build it:
make build - run it:
./adaptive_scroll
Important
you might need to give the script the permissions it needs. see the important note in the homebrew section.