TextMate bundle: Ack in Project (improved)

I use TextMate for work. It’s a good editor, doesn’t get in my way, and I take advantage of relatively few of its nifty features.

One problem with TextMate is that its built-in search is very slow, especially across a large project. Since I work with a full checkout of the deviantART source code, searches can take a while.

So I started using Ack in Project, a TextMate bundle that uses ack to search your project. (Ack is a nifty little tool that combines grep and find, along with a number of useful optimizations for searching checked-out source code.)

However, Ack in Project doesn’t expose a very useful part of ack’s functionality, which is the ability to search just particular filetypes. This has occasionally been a pain – some words appear commonly in PHP and JS files, but I only care about them in the PHP.

So I spent a little while this evening adjusting Ack in Project to let you choose a file type to search.

My Ack in Project tweak

My version is up on github.

If you’d like to use it, do this:

(It was my first time messing with tm_dialog, so I’m not necessarily confident about how I did it. But it works!)