I'm surprised no one has mentioned brew yet in this thread.

http://brew.sh/

It does a good bit of what Jono already suggests....