diff --git a/pages/common/ag.md b/pages/common/ag.md new file mode 100644 index 000000000..742ecdeb4 --- /dev/null +++ b/pages/common/ag.md @@ -0,0 +1,19 @@ +# ag + +> The Silver Searcher. Like ack, but faster. + +- Find files containing "foo" + +`ag foo` + +- Find "foo" in files with a name matching "bar" + +`ag foo -G bar` + +- Find files whose contents match a regular expression: + +`ag '^ba(r|z)$'` + +- Find files with a name matching "foo" + +`ag -g foo`