Z tracks your most used directories, based on 'frecency'. After a short learning phase, z will take you to the most 'frecent' directory that matches ALL of the regexes given on the command line, in order.

You can download the tool here: https://github.com/rupa/z

I've been using this for a few weeks and it greatly speeds jumping around from project to project on the command line. This tool is also demonstrated in the excellent Command Line Power User series by Wes Bos.