I used the code posted above by jnk. Then I used appify to turn it into an OS X app, mathiasbynens.be/notes/shell-script-mac-apps. Then I used Quicksilver to assign my own keyboard shortcut (I chose cmd+L). Terminal is not opening/staying open (as some were concerned) with how I have it set up because I am launching an OS X app instead.
- Follow the answer above by jnk, Lock Screen Command One-LinerLock Screen Command One-Liner
- Use appify to turn it into an OS X app by following the link above in my summary.
- Install Quicksilver.
- Use Quicksilver to assign a keyboard shortcut to launch the new application. It is under 'Triggers.' I enjoy Quicksilver because I love having keyboard shortcuts/hotkeys to launch applications and websites on OS X.