node/deps/npm/doc/cli/npm-adduser.md

56 lines
1.4 KiB
Markdown
Raw Normal View History

npm-adduser(1) -- Add a registry user account
=============================================
## SYNOPSIS
2014-09-25 05:41:07 +08:00
npm adduser [--registry=url] [--scope=@orgname]
## DESCRIPTION
2014-09-25 05:41:07 +08:00
Create or verify a user named `<username>` in the specified registry, and
save the credentials to the `.npmrc` file. If no registry is specified,
the default registry will be used (see `npm-config(7)`).
The username, password, and email are read in from prompts.
You may use this command to change your email address, but not username
or password.
2014-09-25 05:41:07 +08:00
To reset your password, go to <https://www.npmjs.org/forgot>
You may use this command multiple times with the same user account to
authorize on a new machine.
2014-09-25 05:41:07 +08:00
`npm login` is an alias to `adduser` and behaves exactly the same way.
## CONFIGURATION
### registry
Default: http://registry.npmjs.org/
2014-09-25 05:41:07 +08:00
The base URL of the npm package registry. If `scope` is also specified,
this registry will only be used for packages with that scope. See `npm-scope(7)`.
### scope
Default: none
If specified, the user and login credentials given will be associated
with the specified scope. See `npm-scope(7)`. You can use both at the same time,
e.g.
npm adduser --registry=http://myregistry.example.com --scope=@myco
This will set a registry for the given scope and login or create a user for
that registry at the same time.
## SEE ALSO
2013-07-12 23:55:57 +08:00
* npm-registry(7)
* npm-config(1)
2013-07-12 23:55:57 +08:00
* npm-config(7)
* npmrc(5)
* npm-owner(1)
* npm-whoami(1)