codekingpro/portable-devtools
114k
1.TH "NPM-SET" "1" "April 2026" "NPM@11.13.0" ""
2.SH "NAME"
3\fBnpm-set\fR - Set a value in the npm configuration
4.SS "Synopsis"
5.P
6.RS 2
7.nf
8npm set <key>=<value> \[lB]<key>=<value> ...\[rB] (See `npm config`)
9.fi
10.RE
11.P
12Note: This command is unaware of workspaces.
13.SS "Description"
14.P
15Set a value in the npm configuration
16.SS "Configuration"
17.SS "\fBglobal\fR"
18.RS 0
19.IP \(bu 4
20Default: false
21.IP \(bu 4
22Type: Boolean
23.RE 0
24
25.P
26Operates in "global" mode, so that packages are installed into the \fBprefix\fR folder instead of the current working directory. See npm help folders for more on the differences in behavior.
27.RS 0
28.IP \(bu 4
29packages are installed into the \fB{prefix}/lib/node_modules\fR folder, instead of the current working directory.
30.IP \(bu 4
31bin files are linked to \fB{prefix}/bin\fR
32.IP \(bu 4
33man pages are linked to \fB{prefix}/share/man\fR
34.RE 0
35
36.SS "\fBlocation\fR"
37.RS 0
38.IP \(bu 4
39Default: "user" unless \fB--global\fR is passed, which will also set this value to "global"
40.IP \(bu 4
41Type: "global", "user", or "project"
42.RE 0
43
44.P
45When passed to \fBnpm config\fR this refers to which config file to use.
46.P
47When set to "global" mode, packages are installed into the \fBprefix\fR folder instead of the current working directory. See npm help folders for more on the differences in behavior.
48.RS 0
49.IP \(bu 4
50packages are installed into the \fB{prefix}/lib/node_modules\fR folder, instead of the current working directory.
51.IP \(bu 4
52bin files are linked to \fB{prefix}/bin\fR
53.IP \(bu 4
54man pages are linked to \fB{prefix}/share/man\fR
55.RE 0
56
57.SS "See Also"
58.RS 0
59.IP \(bu 4
60npm help "help config"
61.RE 0
62 