A couple of weeks ago I got sick of searching our codebase with Total Commander. So I went googling for a code search engine. This is what I found:
- cs2project: (open-source) developed by Simone as an academic project, using Lucene.Net to index. It's very basic as it's still a new project, but looks really promising. For some reason it only indexed 740 files and then stopped. I'll turn on logging later to see what happened...
- Koders Pro: (commercial) led by Phil Haack, supports over 30 languages and provides lots of statistics. I installed the demo and after the indexing finished, I went browsing and searching and suddenly it asked me to get a (free) account on koders.com. Hmm, no thanks.
- Krugle Enterprise: (commercial) seems cool, but I couldn't find a trial version.
- Fisheye: (commercial) seems more repository-oriented than code-oriented. I mean, you can do full-text queries, but it doesn't give you the exact LoC where the query matched and it doesn't cross-reference classes and types. But when it comes to repository analysis, I think no other product has so many features. It even has a pseudo-SQL language called EyeQL to query the repository! Too bad the trial crashed while indexing our repository...
- OpenGrok: (open-source) developed in Java, under the wing of OpenSolaris, OpenGrok uses Lucene to index source code. It's only about searching and doesn't offer statistics like the commercial products, but it's very good at what it does. It groks (parses) several languages, including C/C++,Java, Shell Scripts like ksh, bash, Perl, Makefiles, XML/HTML/SGML files, ELF files, Java class files, Java Jar files, archive files like TAR, GZip, BZip2, Zip files, man page formats like troff and more, but sadly, still no .NET languages. For the languages it groks, it provides cross-referencing of classes and types. And it gives you repository history search, too!
So I kept OpenGrok, and after installing and configuring, I announced it to the team. But our web designer (one of the coolest guys I have ever worked with) heard "OGrok" instead of OpenGrok (ogro means ogre in spanish). He went on calling it OGrok, and then he even put together an alternative logo, featuring the most famous ogre :-)
It has since become an invaluable tool for us, I can't recommend enough that you install one of these code search engines, it really improves collaboration with your teammates.