Andy Lester: July 2010 Archives

I work in my OS X Terminal window all day long. When I want to run iCal or Address Book, I don't want to be bothered with clicking around to find the app, even though they live in my Dock. I could also use a program launcher like Alfred, which I like, but want it even faster.

For me, the fastest way to open iCal while I'm in the shell is to run "ical" from the prompt, which launches the app.

My ~/bin/ical program is simply

open /Applications/

and my ~/bin/addr is

open "/Applications/Address"

You might think that it's overkill to write a shell program for such a silly task, but it's all about optimizing my time at the keyboard for my common cases.

Someone will note that I could have used a shell alias, and that's true, too. Either way, I want a super simple way to get the apps I use most often.

Ever open up a Terminal window and hit Tab and Bash sits for a few seconds until it finally comes back and asks

Display all 2224 possibilities? (y or n)

Because it went and compiled a list of EVERY executable you could possibly want to execute?

Yeah, me, too, and I hate it. The fix is simple. Add this to your ~/.bashrc

shopt -s no_empty_cmd_completion

No more completion on nothing!

About this Archive

This page is a archive of recent entries written by Andy Lester in July 2010.

Andy Lester: May 2010 is the previous archive.

Find recent content on the main index or look in the archives to find all content.

Other Perl Sites

Other Swell Blogs

  • geek2geek: An ongoing analysis of how geeks communicate, how we fail and how to fix it.