diff options
author | David Peter <sharkdp@users.noreply.github.com> | 2021-11-26 19:30:55 +0100 |
---|---|---|
committer | David Peter <sharkdp@users.noreply.github.com> | 2021-11-26 19:31:06 +0100 |
commit | fba6db5096f8564a54fcc10d04c4eae1db4defa7 (patch) | |
tree | 686f7cdf02e86afe11dc90637481b3774ed0d4bd | |
parent | f2eb1be678341910b0fb5dbfc86f4e7bc83422e4 (diff) |
Modify example to a realistic use case
-rw-r--r-- | README.md | 4 |
1 files changed, 2 insertions, 2 deletions
@@ -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: |