Starting with 10.7 Lion, Apple switched the scrolling direction. This can cause some confusion with people used to older Mac OS versions, or people coming from a Windows background.
I wanted to see if it were possible to allow people to toggle this, so I did some digging. I found a script for trackpads on Super User, but it used GUI scripting. I tried to get something working with the CLI (so I could use “do shell script” instead), but couldn’t find anything that worked.
I also tried to detect the presence of a trackpad beforehand, but didn’t get too far with that. Though most people don’t have a mouse and a trackpad connected at the same time (and expect to use both), changing the scrolling direction applies to both – at least in 10.8.
Update: both scripts are now on GitHub.
Tested with: 10.7, 10.8