From c96a3585935f8fb064fd40828447ba862f86ff5b Mon Sep 17 00:00:00 2001 From: Andrew Gallant Date: Sat, 21 Jul 2018 17:50:54 -0400 Subject: [PATCH] ripgrep: add warning to --pre flag The --pre flag can result in a pretty large performance penalty, so put a warning in the flag documentation. This warning is important because a flag like this could easily wind up in a user's configuration file. --- src/app.rs | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/app.rs b/src/app.rs index 67b7295..6344f53 100644 --- a/src/app.rs +++ b/src/app.rs @@ -1473,6 +1473,10 @@ contents of FILE. This option expects the COMMAND program to either be an absolute path or to be available in your PATH. An empty string COMMAND deactivates this feature. +WARNING: When this flag is set, ripgrep will unconditionally spawn a process +for every file that is searched. Therefore, this can incur a large performance +penalty if you don't otherwise need the flexibility offered by this flag. + A preprocessor is not run when ripgrep is searching stdin. When searching over sets of files that may require one of several decoders