Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

It's been mentioned previous, but you should check out ripgrep - it's even faster than Silver Searcher a lot of the time

https://github.com/BurntSushi/ripgrep



Does anyone not working on million-line codebase ever find themselves limited by grep? I am genuinely curious.


Unfortunately, I work on a million-line codebase.

Grep might be fine 99% of the time, but there's no reason to not drop a ripgrep binary on every machine I use regularly.

Ripgrep is faster across the board and has better defaults for working in Git repositories. Since I'm working with a large codebase managed in Git, it's a no-brainer.


Performance isn't necessarily the only reason that folks use ripgrep. A lot of people like its smart filtering by default. Some don't though. See: https://github.com/BurntSushi/ripgrep/blob/master/FAQ.md#pos...


Do you mean more or less than 1M LOC?

grep is usable on very large code bases, because after the first scan, all the sources are loaded in the file system cache, so the successive grep are done in RAM and are very fast.

So much so that I almost never use ctags despite the improved semantic search (you can find more easily the exact identifiers and distinguish them by category). grep is just as fast and precise enough.




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: