1NPM-REPO(1) NPM-REPO(1)
2
3
4
6 npm-repo - Open package repository page in the browser
7
8 Synopsis
9 npm repo [<pkgname> [<pkgname> ...]]
10
11 Description
12 This command tries to guess at the likely location of a package's
13 repository URL, and then tries to open it using the --browser config
14 ⟨/using-npm/config#browser⟩ param. If no package name is provided, it
15 will search for a package.json in the current folder and use the repos‐
16 itory property.
17
18 Configuration
19 browser
20 • Default: OS X: "open", Windows: "start", Others: "xdg-open"
21
22 • Type: null, Boolean, or String
23
24
25 The browser that is called by npm commands to open websites.
26
27 Set to false to suppress browser behavior and instead print urls to
28 terminal.
29
30 Set to true to use default system URL opener.
31
32 registry
33 • Default: "https://registry.npmjs.org/"
34
35 • Type: URL
36
37
38 The base URL of the npm registry.
39
40 workspace
41 • Default:
42
43 • Type: String (can be set multiple times)
44
45
46 Enable running a command in the context of the configured workspaces of
47 the current project while filtering by running only the workspaces de‐
48 fined by this configuration option.
49
50 Valid values for the workspace config are either:
51
52 • Workspace names
53
54 • Path to a workspace directory
55
56 • Path to a parent workspace directory (will result in selecting all
57 workspaces within that folder)
58
59
60 When set for the npm init command, this may be set to the folder of a
61 workspace which does not yet exist, to create the folder and set it up
62 as a brand new workspace within the project.
63
64 This value is not exported to the environment for child processes.
65
66 workspaces
67 • Default: null
68
69 • Type: null or Boolean
70
71
72 Set to true to run the command in the context of all configured
73 workspaces.
74
75 Explicitly setting this to false will cause commands like install to
76 ignore workspaces altogether. When not set explicitly:
77
78 • Commands that operate on the node_modules tree (install, update,
79 etc.) will link workspaces into the node_modules folder. - Commands
80 that do other things (test, exec, publish, etc.) will operate on
81 the root project, unless one or more workspaces are specified in
82 the workspace config.
83
84
85 This value is not exported to the environment for child processes.
86
87 include-workspace-root
88 • Default: false
89
90 • Type: Boolean
91
92
93 Include the workspace root when workspaces are enabled for a command.
94
95 When false, specifying individual workspaces via the workspace config,
96 or all workspaces via the workspaces flag, will cause npm to operate
97 only on the specified workspaces, and not on the root project.
98
99 This value is not exported to the environment for child processes.
100
101 See Also
102 • npm help docs
103
104 • npm help config
105
106
107
108 November 2023 NPM-REPO(1)