Skip to content

How to make ripgrep not match filenames? #1880

Answered by BurntSushi
RakshithNM asked this question in General
Discussion options

You must be logged in to vote

You aren't running ripgrep though. Or at least, you're not running only ripgrep. You're running some other tool that is either using ripgrep to match filenames or is matching filenames itself.

When asking questions about ripgrep, I definitely prefer that you do it in the context of running rg commands on the command line. In that context, rg pattern only searches the contents of files for pattern. It does not also search filenames.

Replies: 1 comment 1 reply

Comment options

You must be logged in to vote
1 reply
@RakshithNM
Comment options

Answer selected by BurntSushi
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
2 participants