Friday, December 12, 2008

Mac Tricks I Should Have Been Using a Long Time Ago

As I mentioned when I first got my Macbook, I think that sudo sucks. What I failed to do was make my life any easier by developing some shortcuts.

I just finally got around to adding a bunch of aliases to my /etc/profile file:

alias tomcatDebug='sudo /tomcat-dir/bin/ jpda start'
alias tomcatRun='sudo /tomcat-dir/bin/ run'
alias tomcatStart='sudo /tomcat-dir/bin/ start'
alias tomcat='sudo /tomcat-dir/bin/'
alias apacheStop='sudo /apache-dir/bin/apachectl stop'
alias apacheStart='sudo /apache-dir/bin/apachectl start'

I am going to add about a million of these, because I constantly do way too much switching directories and typing. Any self-respecting nerd probably has stuff like this, but for the rest of us dummies, hopefully this will help.
blog comments powered by Disqus