1 .\" Generated with Ronnjs 0.3.8
2 .\" http://github.com/kapouer/ronnjs/
4 .TH "NPM\-VIEW" "1" "November 2013" "" ""
7 \fBnpm-view\fR \-\- View registry info
12 npm view <name>[@<version>] [<field>[\.<subfield>]\.\.\.]
13 npm v <name>[@<version>] [<field>[\.<subfield>]\.\.\.]
18 This command shows data about a package and prints it to the stream
19 referenced by the \fBoutfd\fR config, which defaults to stdout\.
22 To show the package registry entry for the \fBconnect\fR package, you can do
35 The default version is "latest" if unspecified\.
38 Field names can be specified after the package descriptor\.
39 For example, to show the dependencies of the \fBronn\fR package at version
40 0\.3\.5, you could do the following:
45 npm view ronn@0\.3\.5 dependencies
52 You can view child field by separating them with a period\.
53 To view the git repository URL for the latest version of npm, you could
59 npm view npm repository\.url
66 This makes it easy to view information about a dependency with a bit of
67 shell scripting\. For example, to view all the data about the version of
68 opts that ronn depends on, you can do this:
73 npm view opts@$(npm view ronn dependencies\.opts)
80 For fields that are arrays, requesting a non\-numeric field will return
81 all of the values from the objects in the list\. For example, to get all
82 the contributor names for the "express" project, you can do this:
87 npm view express contributors\.email
94 You may also use numeric indices in square braces to specifically select
95 an item in an array field\. To just get the email address of the first
96 contributor in the list, you can do this:
101 npm view express contributors[0]\.email
108 Multiple fields may be specified, and will be printed one after another\.
109 For exampls, to get all the contributor names and email addresses, you
115 npm view express contributors\.name contributors\.email
122 "Person" fields are shown as a string if they would be shown as an
123 object\. So, for example, this will show the list of npm contributors in
124 the shortened string format\. (npm help See \fBpackage\.json\fR for more on this\.)
129 npm view npm contributors
136 If a version range is provided, then data will be printed for every
137 matching version of the package\. This will show which version of jsdom
138 was required by each matching version of yui3:
143 npm view yui3@\'>0\.5\.4\' dependencies\.jsdom
150 If only a single string field for a single version is output, then it
151 will not be colorized or quoted, so as to enable piping the output to
152 another command\. If the field is an object, it will be output as a JavaScript object literal\.
155 If the \-\-json flag is given, the outputted fields will be JSON\.
158 If the version range matches multiple versions, than each printed value
159 will be prefixed with the version it applies to\.
162 If multiple fields are requested, than each of them are prefixed with