From 665b6016e31ee0cf965aba6b8c697240109d30a5 Mon Sep 17 00:00:00 2001 From: Andrew Gallant Date: Sun, 18 Sep 2016 18:18:01 -0400 Subject: add file include/exclude example --- README-NEW.md | 14 ++++++++++++++ 1 file changed, 14 insertions(+) diff --git a/README-NEW.md b/README-NEW.md index f8bc722d..424f23b4 100644 --- a/README-NEW.md +++ b/README-NEW.md @@ -228,6 +228,20 @@ with other search tools!): $ rg '(\p{Lu}\p{Ll}+)\s+(\p{Lu}\p{Ll}+)' --replace '$2, $1' ``` +Search only files matching a particular glob: + +``` +$ rg foo -g 'README.*' +``` + + + +Or exclude files matching a particular glob: + +``` +$ rg foo -g '!*.min.js' +``` + Search only HTML and CSS files: ``` -- cgit v1.2.3