summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorDavid Peter <sharkdp@users.noreply.github.com>2021-11-26 19:30:55 +0100
committerDavid Peter <sharkdp@users.noreply.github.com>2021-11-26 19:31:06 +0100
commitfba6db5096f8564a54fcc10d04c4eae1db4defa7 (patch)
tree686f7cdf02e86afe11dc90637481b3774ed0d4bd
parentf2eb1be678341910b0fb5dbfc86f4e7bc83422e4 (diff)
Modify example to a realistic use case
-rw-r--r--README.md4
1 files changed, 2 insertions, 2 deletions
diff --git a/README.md b/README.md
index df80414..4253b3c 100644
--- a/README.md
+++ b/README.md
@@ -194,9 +194,9 @@ fd … -X ls -lhd --color=always
This pattern is so useful that `fd` provides a shortcut. You can use the `-l`/`--list-details`
option to execute `ls` in this way: `fd … -l`.
-Another example of the `-X` option can be shown with `rg`, using all the search results as arguments:
+The `-X` option is also useful when combining `fd` with [ripgrep](https://github.com/BurntSushi/ripgrep/) (`rg`) in order to search within a certain class of files, like all C++ source files:
```bash
-fd … -X rg -i target
+fd -e cpp -e cxx -e h -e hpp -X rg 'std::cout'
```
Convert all `*.jpg` files to `*.png` files: