1
0
mirror of https://github.com/BurntSushi/ripgrep.git synced 2025-03-17 20:28:03 +02:00

Correct example with --type-add.

Fixes #118.
This commit is contained in:
Andrew Gallant 2016-09-27 18:34:45 -04:00
parent 1df3f0b793
commit 3e892a7a80

View File

@ -214,10 +214,11 @@ $ rg -Tjs foobar
``` ```
To see a list of types supported, run `rg --type-list`. To add a new type, use To see a list of types supported, run `rg --type-list`. To add a new type, use
`--type-add`: `--type-add`, which must be accompanied by a pattern for searching (`rg` won't
persist your type settings):
``` ```
$ rg --type-add 'foo:*.{foo,foobar}' $ rg --type-add 'foo:*.{foo,foobar}' -tfoo bar
``` ```
The type `foo` will now match any file ending with the `.foo` or `.foobar` The type `foo` will now match any file ending with the `.foo` or `.foobar`