Command-line fulltext indexing?

Viewed 4677

We have a huge, old, horrible codebase that makes it nearly impossible to find things when you need it. We're working on improving it, sure... but I often find myself doing massive recursive greps to search through the contents of files to find where things are used.

Is there a tool I can use to build a fulltext index of text files in a directory and then query that from the command-line?

Prefer something that can be run in user-space and doesn't need a daemon. We have many users on our dev server, so I want something that I can search through my instance of the codebase.

4 Answers

I have a similar need to work on a large C++ project. After surveying some tools, I found that id-utils is the best choice because it's really fast on building index and searching patterns.

Based on id-utils, I made a command line tool and vim plugin to fix my need:

https://github.com/fcamel/gj

Hope it helps.

Related