From 72e839cf3c765ee6cca37591e0034e4df7346d50 Mon Sep 17 00:00:00 2001 From: vikash Date: Wed, 14 May 2025 21:26:47 +0530 Subject: [PATCH] doc: clarify --watch and --watch-path usage with --run --- doc/api/cli.md | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/doc/api/cli.md b/doc/api/cli.md index ee4e9e85254135..3371c26675ed73 100644 --- a/doc/api/cli.md +++ b/doc/api/cli.md @@ -2259,6 +2259,10 @@ different folders where multiple `node_modules` directories are present, if `--run` executes the command in the directory containing the related `package.json`. +Note: This option only has an effect when used with either `--watch` or `--watch-path`. +Without one of these flags, `--run` will be ignored during process restarts. + + For example, the following command will run the `test` script of the `package.json` in the current folder: