diff options
author | Ruy Adorno <ruyadorno@hotmail.com> | 2021-05-20 15:54:50 -0400 |
---|---|---|
committer | Ruy Adorno <ruyadorno@hotmail.com> | 2021-05-21 10:58:00 -0400 |
commit | aa0e4eb27f922017d7a05f41b483e57188dbd3e7 (patch) | |
tree | 531d4a5bfd66f585c715ea51ca05fb9d7f74392a /deps/npm/docs/output/commands/npm-run-script.html | |
parent | 50f076c4f59bbaaf129e858abfe8327b64d1113c (diff) | |
download | node-new-aa0e4eb27f922017d7a05f41b483e57188dbd3e7.tar.gz |
deps: upgrade npm to 7.14.0
PR-URL: https://github.com/nodejs/node/pull/38750
Reviewed-By: Myles Borins <myles.borins@gmail.com>
Reviewed-By: Beth Griggs <bgriggs@redhat.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Diffstat (limited to 'deps/npm/docs/output/commands/npm-run-script.html')
-rw-r--r-- | deps/npm/docs/output/commands/npm-run-script.html | 83 |
1 files changed, 45 insertions, 38 deletions
diff --git a/deps/npm/docs/output/commands/npm-run-script.html b/deps/npm/docs/output/commands/npm-run-script.html index 1e47bfec10..54afe9f240 100644 --- a/deps/npm/docs/output/commands/npm-run-script.html +++ b/deps/npm/docs/output/commands/npm-run-script.html @@ -141,7 +141,7 @@ npm command-line interface <section id="table_of_contents"> <h2 id="table-of-contents">Table of contents</h2> -<div id="_table_of_contents"><ul><li><a href="#synopsis">Synopsis</a></li><li><a href="#description">Description</a></li><li><a href="#workspaces-support">Workspaces support</a></li><ul><li><a href="#filtering-workspaces">Filtering workspaces</a></li></ul><li><a href="#configuration">Configuration</a></li><ul><li><a href="#if-present">if-present</a></li><li><a href="#ignore-scripts">ignore-scripts</a></li><li><a href="#script-shell">script-shell</a></li><li><a href="#silent">silent</a></li><li><a href="#workspace">workspace</a></li><li><a href="#workspaces">workspaces</a></li></ul><li><a href="#see-also">See Also</a></li></ul></div> +<div id="_table_of_contents"><ul><li><a href="#synopsis">Synopsis</a></li><li><a href="#description">Description</a></li><li><a href="#workspaces-support">Workspaces support</a></li><ul><li><a href="#filtering-workspaces">Filtering workspaces</a></li></ul><li><a href="#configuration">Configuration</a></li><ul><li><a href="#workspace"><code>workspace</code></a></li><li><a href="#workspaces"><code>workspaces</code></a></li><li><a href="#if-present"><code>if-present</code></a></li><li><a href="#ignore-scripts"><code>ignore-scripts</code></a></li><li><a href="#script-shell"><code>script-shell</code></a></li></ul><li><a href="#see-also">See Also</a></li></ul></div> </section> <div id="_content"><h3 id="synopsis">Synopsis</h3> @@ -238,56 +238,63 @@ shorthand, e.g:</p> <p>This last command will run <code>test</code> in both <code>./packages/a</code> and <code>./packages/b</code> packages.</p> <h3 id="configuration">Configuration</h3> -<h4 id="if-present">if-present</h4> +<!-- raw HTML omitted --> +<!-- raw HTML omitted --> +<h4 id="workspace"><code>workspace</code></h4> <ul> -<li>Type: Boolean</li> -<li>Default: false</li> -</ul> -<p>You can use the <code>--if-present</code> flag to avoid exiting with a non-zero exit code -when the script is undefined. This lets you run potentially undefined scripts -without breaking the execution chain.</p> -<h4 id="ignore-scripts">ignore-scripts</h4> -<ul> -<li>Type: Boolean</li> -<li>Default: false</li> +<li>Default:</li> +<li>Type: String (can be set multiple times)</li> </ul> -<p>Skips running <code>pre</code> and <code>post</code> scripts.</p> -<h4 id="script-shell">script-shell</h4> +<p>Enable running a command in the context of the configured workspaces of the +current project while filtering by running only the workspaces defined by +this configuration option.</p> +<p>Valid values for the <code>workspace</code> config are either:</p> <ul> -<li>Type: String</li> -<li>Default: <code>null</code></li> +<li>Workspace names</li> +<li>Path to a workspace directory</li> +<li>Path to a parent workspace directory (will result to selecting all of the +nested workspaces)</li> </ul> -<p>Optional custom script to use to execute the command. If not defined defaults -to <code>/bin/sh</code> on Unix, defaults to <code>env.comspec</code> or <code>cmd.exe</code> on Windows.</p> -<h4 id="silent">silent</h4> +<p>When set for the <code>npm init</code> command, this may be set to the folder of a +workspace which does not yet exist, to create the folder and set it up as a +brand new workspace within the project.</p> +<p>This value is not exported to the environment for child processes.</p> +<h4 id="workspaces"><code>workspaces</code></h4> <ul> -<li>Type: Boolean</li> <li>Default: false</li> +<li>Type: Boolean</li> </ul> -<p>You can use the <code>--silent</code> flag to prevent showing <code>npm ERR!</code> output on error.</p> -<h4 id="workspace">workspace</h4> +<p>Enable running a command in the context of <strong>all</strong> the configured +workspaces.</p> +<p>This value is not exported to the environment for child processes.</p> +<h4 id="if-present"><code>if-present</code></h4> <ul> -<li>Alias: <code>-w</code></li> -<li>Type: Array</li> -<li>Default: <code>[]</code></li> +<li>Default: false</li> +<li>Type: Boolean</li> </ul> -<p>Enable running scripts in the context of workspaces while also filtering by -the provided names or paths provided.</p> -<p>Valid values for the <code>workspace</code> config are either:</p> +<p>If true, npm will not exit with an error code when <code>run-script</code> is invoked +for a script that isn’t defined in the <code>scripts</code> section of <code>package.json</code>. +This option can be used when it’s desirable to optionally run a script when +it’s present and fail if the script fails. This is useful, for example, when +running scripts that may only apply for some builds in an otherwise generic +CI setup.</p> +<h4 id="ignore-scripts"><code>ignore-scripts</code></h4> <ul> -<li>Workspace names</li> -<li>Path to a workspace directory</li> -<li>Path to a parent workspace directory (will result to selecting all of the -children workspaces)</li> +<li>Default: false</li> +<li>Type: Boolean</li> </ul> -<h4 id="workspaces">workspaces</h4> +<p>If true, npm does not run scripts specified in package.json files.</p> +<p>Note that commands explicitly intended to run a particular script, such as +<code>npm start</code>, <code>npm stop</code>, <code>npm restart</code>, <code>npm test</code>, and <code>npm run-script</code> +will still run their intended script if <code>ignore-scripts</code> is set, but they +will <em>not</em> run any pre- or post-scripts.</p> +<h4 id="script-shell"><code>script-shell</code></h4> <ul> -<li>Alias: <code>--ws</code></li> -<li>Type: Boolean</li> -<li>Default: <code>false</code></li> +<li>Default: ‘/bin/sh’ on POSIX systems, ‘cmd.exe’ on Windows</li> +<li>Type: null or String</li> </ul> -<p>Run scripts in the context of all configured workspaces for the current -project.</p> +<p>The shell to use for scripts run with the <code>npm exec</code>, <code>npm run</code> and <code>npm init <pkg></code> commands.</p> +<!-- raw HTML omitted --> <h3 id="see-also">See Also</h3> <ul> <li><a href="../using-npm/scripts.html">npm scripts</a></li> |