.TH "NPM\-REBUILD" "1" "August 2021" "" "" .SH "NAME" \fBnpm-rebuild\fR \- Rebuild a package .SS Synopsis .P .RS 2 .nf npm rebuild [[<@scope>/][@] \.\.\.] alias: rb .fi .RE .SS Description .P This command runs the \fBnpm build\fP command on the matched folders\. This is useful when you install a new version of node, and must recompile all your C++ addons with the new binary\. It is also useful when installing with \fB\-\-ignore\-scripts\fP and \fB\-\-no\-bin\-links\fP, to explicitly choose which packages to build and/or link bins\. .P If one or more package names (and optionally version ranges) are provided, then only packages with a name and version matching one of the specifiers will be rebuilt\. .SS Configuration .SS \fBglobal\fP .RS 0 .IP \(bu 2 Default: false .IP \(bu 2 Type: Boolean .RE .P Operates in "global" mode, so that packages are installed into the \fBprefix\fP folder instead of the current working directory\. See npm help folders for more on the differences in behavior\. .RS 0 .IP \(bu 2 packages are installed into the \fB{prefix}/lib/node_modules\fP folder, instead of the current working directory\. .IP \(bu 2 bin files are linked to \fB{prefix}/bin\fP .IP \(bu 2 man pages are linked to \fB{prefix}/share/man\fP .RE .SS \fBbin\-links\fP .RS 0 .IP \(bu 2 Default: true .IP \(bu 2 Type: Boolean .RE .P Tells npm to create symlinks (or \fB\|\.cmd\fP shims on Windows) for package executables\. .P Set to false to have it not do this\. This can be used to work around the fact that some file systems don't support symlinks, even on ostensibly Unix systems\. .SS \fBignore\-scripts\fP .RS 0 .IP \(bu 2 Default: false .IP \(bu 2 Type: Boolean .RE .P If true, npm does not run scripts specified in package\.json files\. .P Note that commands explicitly intended to run a particular script, such as \fBnpm start\fP, \fBnpm stop\fP, \fBnpm restart\fP, \fBnpm test\fP, and \fBnpm run\-script\fP will still run their intended script if \fBignore\-scripts\fP is set, but they will \fInot\fR run any pre\- or post\-scripts\. .SS \fBworkspace\fP .RS 0 .IP \(bu 2 Default: .IP \(bu 2 Type: String (can be set multiple times) .RE .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 Valid values for the \fBworkspace\fP config are either: .RS 0 .IP \(bu 2 Workspace names .IP \(bu 2 Path to a workspace directory .IP \(bu 2 Path to a parent workspace directory (will result to selecting all of the nested workspaces) .RE .P When set for the \fBnpm init\fP 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 This value is not exported to the environment for child processes\. .SS \fBworkspaces\fP .RS 0 .IP \(bu 2 Default: false .IP \(bu 2 Type: Boolean .RE .P Enable running a command in the context of \fBall\fR the configured workspaces\. .P This value is not exported to the environment for child processes\. .SS See Also .RS 0 .IP \(bu 2 npm help install .RE