Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

npm access: add page #14400

Merged
merged 6 commits into from
Oct 28, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
32 changes: 32 additions & 0 deletions pages/common/npm-access.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
# npm access

> Set access level on published packages.
> More information: <https://docs.npmjs.com/cli/npm-access>.

- List packages for a user or scope:

`npm access list packages {{user|scope|scope:team}} {{package_name}}`

- List collaborators on a package:

`npm access list collaborators {{package_name}} {{username}}`

- Get status of a package:

`npm access get status {{package_name}}`

- Set package status (public or private):

`npm access set status={{public|private}} {{package_name}}`

- Grant access to a package:

`npm access grant {{read-only|read-write}} {{scope:team}} {{package_name}}`

- Revoke access to a package:

`npm access revoke {{scope:team}} {{package_name}}`

- Configure two-factor authentication requirement:

`npm access set mfa={{none|publish|automation}} {{package_name}}`