pnpm team
Added in: v11.13.0
Manages organization teams and team memberships on the registry.
pnpm team create <scope:team> [--otp <code>]
pnpm team destroy <scope:team> [--otp <code>]
pnpm team add <scope:team> <user> [--otp <code>]
pnpm team rm <scope:team> <user> [--otp <code>]
pnpm team ls <scope|scope:team>
Team references are always written with a leading @: @myorg for an organization and @myorg:developers for a team within it.
子命令
create
Create a new team in an organization.
pnpm team create @myorg:developers
destroy
Destroy an existing team.
pnpm team destroy @myorg:developers
add
Add a user to an existing team.
pnpm team add @myorg:developers alice
rm
Remove a user from an existing team.
pnpm team rm @myorg:developers alice
ls
List the teams in an organization, or the members of a team.
pnpm team ls @myorg
pnpm team ls @myorg:developers
Aliases: list. If no subcommand is given and the first argument looks like a scope or team, ls is assumed, so pnpm team @myorg is equivalent to pnpm team ls @myorg.
配置项
--registry <url>
要用于此操作的 npm 注册源的基本 URL。 A registry configured for the organization's scope (via registries) is respected.
--otp <code>
当注册源需要双因素身份验证时,此选项提供一次性密码。 It applies to create, destroy, add, and rm.
--parseable
Print the results of ls as bare names, one per line, without headers or indentation.
--json
Print the results of ls as a JSON array of names. Takes precedence over --parseable.