You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
@antfu/ni has an na command, which is agent alias. Running na install or na run build will detect and use the right package manager to execute the corresponding command.
Backgroud
@antfu/ni has an
na
command, which is agent alias. Runningna install
orna run build
will detect and use the right package manager to execute the corresponding command.na install
➡️npm install
/pnpm install
/yarn install
na run build
➡️npm run build
/pnpm run build
/yarn run build
na foo bar
➡️npm foo bar
/pnpm foo bar
/yarn foo bar
Solution
It's good provide a sub-command named
agent
incorepack
. So that we don't need@antfu/ni
corepack agent install
➡️npm install
/pnpm install
/yarn install
corepack agent run build
➡️npm run build
/pnpm run build
/yarn run build
corepack agent foo bar
➡️npm foo bar
/pnpm foo bar
/yarn foo bar
If there is no
packageManager
field inpackage.json
, usenpm
by default.Addintion
Providing a
cpa
command which is the alias ofcorepack agent
will be great.The text was updated successfully, but these errors were encountered: