Use npm as fallback if pnpm isn't available & more robust pnpm installation

This commit is contained in:
Will Chen
2025-04-18 21:43:46 -07:00
parent 14d09f080f
commit 7ac07aa0ce
2 changed files with 11 additions and 7 deletions

View File

@@ -50,7 +50,7 @@ export function registerNodeHandlers() {
// If not, try to install it using corepack.
// If both fail, then pnpm is not available.
checkCommandExists(
"pnpm --version || corepack enable pnpm && pnpm --version"
"pnpm --version || (corepack enable pnpm && pnpm --version) || (npm install -g pnpm@latest-10 && pnpm --version)"
),
]);
// Default to mac download url.