Verify the presence of the
NPM_TOKEN environment variable, create or update the
.npmrc file with the token and verify the token is valid.
package.json version and create the
npm package tarball.
Publish to the
Npm registry authentication
npm authentication configuration is required and can be set via environment variables.
Both the token and the legacy (
Note: Only the
auth-only level of npm two-factor authentication is supported, semantic-release will not work with the default
||Npm token created via npm token create|
||Npm username created via npm adduser or on npmjs.com|
||Password of the npm user.|
||Email address associated with the npm user|
NPM_TOKEN for token authentication or
NPM_EMAIL for legacy authentication
||Whether to publish the
||Directory path to publish.||
||Directory path in which to write the the package tarball. If
pkgRoot directory must contains a
package.json. The version will be updated only in the
npm-shrinkwrap.json within the
The plugins are used by default by semantic-release so no specific configuration is requiered to use them.
Each individual plugin can be disabled, replaced or used with other plugins in the
tarballDir option can be used to skip the publishing to the
npm registry and instead, release the package tarball with another plugin. For example with the github plugin:
When publishing from a sub-directory with the
pkgRoot option, the
npm-shrinkwrap.json updated with the new version can be moved to another directory with a
postpublish npm script. For example with the git plugin: