1 .TH "NPM\-PUBLISH" "1" "October 2016" "" ""
3 \fBnpm-publish\fR \- Publish a package
8 npm publish <tarball> [\-\-tag <tag>] [\-\-access <public|restricted>]
9 npm publish <folder> [\-\-tag <tag>] [\-\-access <public|restricted>]
14 Publishes a package to the registry so that it can be installed by name\. All
15 files in the package directory are included if no local \fB\|\.gitignore\fP or
16 \fB\|\.npmignore\fP file is present\. See npm help 7 \fBnpm\-developers\fP for full details on
17 what's included in the published package, as well as details on how the package
20 By default npm will publish to the public registry\. This can be overridden by
21 specifying a different default registry or using a npm help 7 \fBnpm\-scope\fP in the name
22 (see npm help 5 \fBpackage\.json\fP)\.
26 A folder containing a package\.json file
29 A url or file path to a gzipped tar archive containing a single folder
30 with a package\.json file inside\.
33 Registers the published package with the given tag, such that \fBnpm install
34 <name>@<tag>\fP will install this version\. By default, \fBnpm publish\fP updates
35 and \fBnpm install\fP installs the \fBlatest\fP tag\. See npm help \fBnpm\-dist\-tag\fP for
38 \fB[\-\-access <public|restricted>]\fP
39 Tells the registry whether this package should be published as public or
40 restricted\. Only applies to scoped packages, which default to \fBrestricted\fP\|\.
41 If you don't have a paid account, you must publish with \fB\-\-access public\fP
42 to publish scoped packages\.
46 Fails if the package name and version combination already exists in
47 the specified registry\.
49 Once a package is published with a given name and version, that
50 specific name and version combination can never be used again, even if
51 it is removed with npm help unpublish\.