From 0487555a6088639972cb652262568bc6162add33 Mon Sep 17 00:00:00 2001 From: dz-at-tc <49352191+dz-at-tc@users.noreply.github.com> Date: Sun, 17 Oct 2021 15:35:05 -0400 Subject: [PATCH] rgrep: add page (#7021) --- pages/linux/rgrep.md | 25 +++++++++++++++++++++++++ 1 file changed, 25 insertions(+) create mode 100644 pages/linux/rgrep.md diff --git a/pages/linux/rgrep.md b/pages/linux/rgrep.md new file mode 100644 index 000000000..c3bf98514 --- /dev/null +++ b/pages/linux/rgrep.md @@ -0,0 +1,25 @@ +# rgrep + +> Recursively find patterns in files using regular expressions. +> Equivalent to `grep -r`. +> More information: . + +- Recursively search for a pattern in the current working directory: + +`rgrep "{{search_pattern}}"` + +- Recursively search for a case-insensitive pattern in the current working directory: + +`rgrep --ignore-case "{{search_pattern}}"` + +- Recursively search for an extended regular expression pattern (supports `?`, `+`, `{}`, `()` and `|`) in the current working directory: + +`rgrep --extended-regexp "{{search_pattern}}"` + +- Recursively search for an exact string (disables regular expressions) in the current working directory: + +`rgrep --fixed-strings "{{exact_string}}"` + +- Recursively search for a pattern in a specified directory (or file): + +`rgrep "{{search_pattern}}" {{path/to/file_or_directory}}`