npm-install-test.1 10 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359
  1. .TH "NPM\-INSTALL\-TEST" "1" "October 2021" "" ""
  2. .SH "NAME"
  3. \fBnpm-install-test\fR \- Install package(s) and run tests
  4. .SS Synopsis
  5. .P
  6. .RS 2
  7. .nf
  8. npm install\-test (with no args, in package dir)
  9. npm install\-test [<@scope>/]<name>
  10. npm install\-test [<@scope>/]<name>@<tag>
  11. npm install\-test [<@scope>/]<name>@<version>
  12. npm install\-test [<@scope>/]<name>@<version range>
  13. npm install\-test <tarball file>
  14. npm install\-test <tarball url>
  15. npm install\-test <folder>
  16. alias: npm it
  17. common options: [\-\-save|\-\-save\-dev|\-\-save\-optional] [\-\-save\-exact] [\-\-dry\-run]
  18. .fi
  19. .RE
  20. .SS Description
  21. .P
  22. This command runs an \fBnpm install\fP followed immediately by an \fBnpm test\fP\|\. It
  23. takes exactly the same arguments as \fBnpm install\fP\|\.
  24. .SS Configuration
  25. <!\-\- AUTOGENERATED CONFIG DESCRIPTIONS START \-\->
  26. <!\-\- automatically generated, do not edit manually \-\->
  27. <!\-\- see lib/utils/config/definitions\.js \-\->
  28. .SS \fBsave\fP
  29. .RS 0
  30. .IP \(bu 2
  31. Default: true
  32. .IP \(bu 2
  33. Type: Boolean
  34. .RE
  35. .P
  36. Save installed packages to a package\.json file as dependencies\.
  37. .P
  38. When used with the \fBnpm rm\fP command, removes the dependency from
  39. package\.json\.
  40. <!\-\- automatically generated, do not edit manually \-\->
  41. <!\-\- see lib/utils/config/definitions\.js \-\->
  42. .SS \fBsave\-exact\fP
  43. .RS 0
  44. .IP \(bu 2
  45. Default: false
  46. .IP \(bu 2
  47. Type: Boolean
  48. .RE
  49. .P
  50. Dependencies saved to package\.json will be configured with an exact version
  51. rather than using npm's default semver range operator\.
  52. <!\-\- automatically generated, do not edit manually \-\->
  53. <!\-\- see lib/utils/config/definitions\.js \-\->
  54. .SS \fBglobal\fP
  55. .RS 0
  56. .IP \(bu 2
  57. Default: false
  58. .IP \(bu 2
  59. Type: Boolean
  60. .RE
  61. .P
  62. Operates in "global" mode, so that packages are installed into the \fBprefix\fP
  63. folder instead of the current working directory\. See
  64. npm help folders for more on the differences in behavior\.
  65. .RS 0
  66. .IP \(bu 2
  67. packages are installed into the \fB{prefix}/lib/node_modules\fP folder, instead
  68. of the current working directory\.
  69. .IP \(bu 2
  70. bin files are linked to \fB{prefix}/bin\fP
  71. .IP \(bu 2
  72. man pages are linked to \fB{prefix}/share/man\fP
  73. .RE
  74. <!\-\- automatically generated, do not edit manually \-\->
  75. <!\-\- see lib/utils/config/definitions\.js \-\->
  76. .SS \fBglobal\-style\fP
  77. .RS 0
  78. .IP \(bu 2
  79. Default: false
  80. .IP \(bu 2
  81. Type: Boolean
  82. .RE
  83. .P
  84. Causes npm to install the package into your local \fBnode_modules\fP folder with
  85. the same layout it uses with the global \fBnode_modules\fP folder\. Only your
  86. direct dependencies will show in \fBnode_modules\fP and everything they depend
  87. on will be flattened in their \fBnode_modules\fP folders\. This obviously will
  88. eliminate some deduping\. If used with \fBlegacy\-bundling\fP, \fBlegacy\-bundling\fP
  89. will be preferred\.
  90. <!\-\- automatically generated, do not edit manually \-\->
  91. <!\-\- see lib/utils/config/definitions\.js \-\->
  92. .SS \fBlegacy\-bundling\fP
  93. .RS 0
  94. .IP \(bu 2
  95. Default: false
  96. .IP \(bu 2
  97. Type: Boolean
  98. .RE
  99. .P
  100. Causes npm to install the package such that versions of npm prior to 1\.4,
  101. such as the one included with node 0\.8, can install the package\. This
  102. eliminates all automatic deduping\. If used with \fBglobal\-style\fP this option
  103. will be preferred\.
  104. <!\-\- automatically generated, do not edit manually \-\->
  105. <!\-\- see lib/utils/config/definitions\.js \-\->
  106. .SS \fBstrict\-peer\-deps\fP
  107. .RS 0
  108. .IP \(bu 2
  109. Default: false
  110. .IP \(bu 2
  111. Type: Boolean
  112. .RE
  113. .P
  114. If set to \fBtrue\fP, and \fB\-\-legacy\-peer\-deps\fP is not set, then \fIany\fR
  115. conflicting \fBpeerDependencies\fP will be treated as an install failure, even
  116. if npm could reasonably guess the appropriate resolution based on non\-peer
  117. dependency relationships\.
  118. .P
  119. By default, conflicting \fBpeerDependencies\fP deep in the dependency graph will
  120. be resolved using the nearest non\-peer dependency specification, even if
  121. doing so will result in some packages receiving a peer dependency outside
  122. the range set in their package's \fBpeerDependencies\fP object\.
  123. .P
  124. When such and override is performed, a warning is printed, explaining the
  125. conflict and the packages involved\. If \fB\-\-strict\-peer\-deps\fP is set, then
  126. this warning is treated as a failure\.
  127. <!\-\- automatically generated, do not edit manually \-\->
  128. <!\-\- see lib/utils/config/definitions\.js \-\->
  129. .SS \fBpackage\-lock\fP
  130. .RS 0
  131. .IP \(bu 2
  132. Default: true
  133. .IP \(bu 2
  134. Type: Boolean
  135. .RE
  136. .P
  137. If set to false, then ignore \fBpackage\-lock\.json\fP files when installing\. This
  138. will also prevent \fIwriting\fR \fBpackage\-lock\.json\fP if \fBsave\fP is true\.
  139. .P
  140. When package package\-locks are disabled, automatic pruning of extraneous
  141. modules will also be disabled\. To remove extraneous modules with
  142. package\-locks disabled use \fBnpm prune\fP\|\.
  143. <!\-\- automatically generated, do not edit manually \-\->
  144. <!\-\- see lib/utils/config/definitions\.js \-\->
  145. .SS \fBomit\fP
  146. .RS 0
  147. .IP \(bu 2
  148. Default: 'dev' if the \fBNODE_ENV\fP environment variable is set to
  149. \|'production', otherwise empty\.
  150. .IP \(bu 2
  151. Type: "dev", "optional", or "peer" (can be set multiple times)
  152. .RE
  153. .P
  154. Dependency types to omit from the installation tree on disk\.
  155. .P
  156. Note that these dependencies \fIare\fR still resolved and added to the
  157. \fBpackage\-lock\.json\fP or \fBnpm\-shrinkwrap\.json\fP file\. They are just not
  158. physically installed on disk\.
  159. .P
  160. If a package type appears in both the \fB\-\-include\fP and \fB\-\-omit\fP lists, then
  161. it will be included\.
  162. .P
  163. If the resulting omit list includes \fB\|'dev'\fP, then the \fBNODE_ENV\fP environment
  164. variable will be set to \fB\|'production'\fP for all lifecycle scripts\.
  165. <!\-\- automatically generated, do not edit manually \-\->
  166. <!\-\- see lib/utils/config/definitions\.js \-\->
  167. .SS \fBignore\-scripts\fP
  168. .RS 0
  169. .IP \(bu 2
  170. Default: false
  171. .IP \(bu 2
  172. Type: Boolean
  173. .RE
  174. .P
  175. If true, npm does not run scripts specified in package\.json files\.
  176. .P
  177. Note that commands explicitly intended to run a particular script, such as
  178. \fBnpm start\fP, \fBnpm stop\fP, \fBnpm restart\fP, \fBnpm test\fP, and \fBnpm run\-script\fP
  179. will still run their intended script if \fBignore\-scripts\fP is set, but they
  180. will \fInot\fR run any pre\- or post\-scripts\.
  181. <!\-\- automatically generated, do not edit manually \-\->
  182. <!\-\- see lib/utils/config/definitions\.js \-\->
  183. .SS \fBaudit\fP
  184. .RS 0
  185. .IP \(bu 2
  186. Default: true
  187. .IP \(bu 2
  188. Type: Boolean
  189. .RE
  190. .P
  191. When "true" submit audit reports alongside the current npm command to the
  192. default registry and all registries configured for scopes\. See the
  193. documentation for npm help \fBaudit\fP for details on what is
  194. submitted\.
  195. <!\-\- automatically generated, do not edit manually \-\->
  196. <!\-\- see lib/utils/config/definitions\.js \-\->
  197. .SS \fBbin\-links\fP
  198. .RS 0
  199. .IP \(bu 2
  200. Default: true
  201. .IP \(bu 2
  202. Type: Boolean
  203. .RE
  204. .P
  205. Tells npm to create symlinks (or \fB\|\.cmd\fP shims on Windows) for package
  206. executables\.
  207. .P
  208. Set to false to have it not do this\. This can be used to work around the
  209. fact that some file systems don't support symlinks, even on ostensibly Unix
  210. systems\.
  211. <!\-\- automatically generated, do not edit manually \-\->
  212. <!\-\- see lib/utils/config/definitions\.js \-\->
  213. .SS \fBfund\fP
  214. .RS 0
  215. .IP \(bu 2
  216. Default: true
  217. .IP \(bu 2
  218. Type: Boolean
  219. .RE
  220. .P
  221. When "true" displays the message at the end of each \fBnpm install\fP
  222. acknowledging the number of dependencies looking for funding\. See npm help \fBnpm
  223. fund\fP for details\.
  224. <!\-\- automatically generated, do not edit manually \-\->
  225. <!\-\- see lib/utils/config/definitions\.js \-\->
  226. .SS \fBdry\-run\fP
  227. .RS 0
  228. .IP \(bu 2
  229. Default: false
  230. .IP \(bu 2
  231. Type: Boolean
  232. .RE
  233. .P
  234. Indicates that you don't want npm to make any changes and that it should
  235. only report what it would have done\. This can be passed into any of the
  236. commands that modify your local installation, eg, \fBinstall\fP, \fBupdate\fP,
  237. \fBdedupe\fP, \fBuninstall\fP, as well as \fBpack\fP and \fBpublish\fP\|\.
  238. .P
  239. Note: This is NOT honored by other network related commands, eg \fBdist\-tags\fP,
  240. \fBowner\fP, etc\.
  241. <!\-\- automatically generated, do not edit manually \-\->
  242. <!\-\- see lib/utils/config/definitions\.js \-\->
  243. .SS \fBworkspace\fP
  244. .RS 0
  245. .IP \(bu 2
  246. Default:
  247. .IP \(bu 2
  248. Type: String (can be set multiple times)
  249. .RE
  250. .P
  251. Enable running a command in the context of the configured workspaces of the
  252. current project while filtering by running only the workspaces defined by
  253. this configuration option\.
  254. .P
  255. Valid values for the \fBworkspace\fP config are either:
  256. .RS 0
  257. .IP \(bu 2
  258. Workspace names
  259. .IP \(bu 2
  260. Path to a workspace directory
  261. .IP \(bu 2
  262. Path to a parent workspace directory (will result in selecting all
  263. workspaces within that folder)
  264. .RE
  265. .P
  266. When set for the \fBnpm init\fP command, this may be set to the folder of a
  267. workspace which does not yet exist, to create the folder and set it up as a
  268. brand new workspace within the project\.
  269. .P
  270. This value is not exported to the environment for child processes\.
  271. <!\-\- automatically generated, do not edit manually \-\->
  272. <!\-\- see lib/utils/config/definitions\.js \-\->
  273. .SS \fBworkspaces\fP
  274. .RS 0
  275. .IP \(bu 2
  276. Default: null
  277. .IP \(bu 2
  278. Type: null or Boolean
  279. .RE
  280. .P
  281. Set to true to run the command in the context of \fBall\fR configured
  282. workspaces\.
  283. .P
  284. Explicitly setting this to false will cause commands like \fBinstall\fP to
  285. ignore workspaces altogether\. When not set explicitly:
  286. .RS 0
  287. .IP \(bu 2
  288. Commands that operate on the \fBnode_modules\fP tree (install, update, etc\.)
  289. will link workspaces into the \fBnode_modules\fP folder\. \- Commands that do
  290. other things (test, exec, publish, etc\.) will operate on the root project,
  291. \fIunless\fR one or more workspaces are specified in the \fBworkspace\fP config\.
  292. .RE
  293. .P
  294. This value is not exported to the environment for child processes\.
  295. <!\-\- automatically generated, do not edit manually \-\->
  296. <!\-\- see lib/utils/config/definitions\.js \-\->
  297. .SS \fBinclude\-workspace\-root\fP
  298. .RS 0
  299. .IP \(bu 2
  300. Default: false
  301. .IP \(bu 2
  302. Type: Boolean
  303. .RE
  304. .P
  305. Include the workspace root when workspaces are enabled for a command\.
  306. .P
  307. When false, specifying individual workspaces via the \fBworkspace\fP config, or
  308. all workspaces via the \fBworkspaces\fP flag, will cause npm to operate only on
  309. the specified workspaces, and not on the root project\.
  310. <!\-\- automatically generated, do not edit manually \-\->
  311. <!\-\- see lib/utils/config/definitions\.js \-\->
  312. <!\-\- AUTOGENERATED CONFIG DESCRIPTIONS END \-\->
  313. .SS See Also
  314. .RS 0
  315. .IP \(bu 2
  316. npm help install
  317. .IP \(bu 2
  318. npm help install\-ci\-test
  319. .IP \(bu 2
  320. npm help test
  321. .RE