3 ms·
That addition was an incredible time savings in my average search, I'm very grateful. A more prominent mention, and a sample script, would be very useful imho.
by SanchoPanda 8y ago
That addition was an incredible time savings in my average search, I'm very grateful.
A more prominent mention, and a sample script, would be very useful imho. Just googling for a way to do this for even just one of these file types yields inferior commercial solutions at best, often just nothing.
And while I'm not sure how to make it much faster from a search perspective, I was able to find a 40% improvement in invocation by switching from rgpre to rgg as my alais.
I ended here:
alias rgg='rg -i --pre-glob '*.{pdf,xlsx,xls,docx,doc,pptx,ppt,html,epub,mobi}' --pre rgpre'
- burntsushi 8y agoHah nice! I'll noodle on this and figure out how to publicize it more. Your script would be very helpful as an example. Do you mind if I use it in the docs somewhere?
- SanchoPanda 8y agoPlease feel free. Even a cursory mention of the ability at the end of the readme would likely help many. With a verbatim script and verbatim command using it helping many more. I only stumbled upon this feature with enough context to really get it in the Ubuntu man pages and I don't know if I ever would have gotten to the pre-glob feature to be honest. I do believe that technically oriented non-programmers would be the biggest winners from more exposure around it.
- burntsushi 8y agoGreat! I filed an issue for it: https://github.com/BurntSushi/ripgrep/issues/1252 https://github.com/BurntSushi/ripgrep/issues/1252