MacOS快速配置pnpm与切换淘宝镜像

1.确认 Node 版本

需 ≥ 16.9(建议 18+/20+ LTS)。

bash 复制代码
node -v

2.启用 Corepack

bash 复制代码
corepack enable

3.安装 / 激活 pnpm

bash 复制代码
corepack prepare pnpm@latest --activate

4.验证

bash 复制代码
pnpm -v

5.设置淘宝镜像(永久生效)

复制这两条命令,直接粘贴到终端执行

bash 复制代码
pnpm config set registry https://registry.npmmirror.com
pnpm config set disturl https://npmmirror.com/dist
相关推荐
Teleger15 小时前
蓝牙 MAC 扫描匹配器
macos
刘婉晴15 小时前
【漏扫工具篇】Mac 系统上 Xray 的安装与使用
macos
寒水馨1 天前
macOS下载、安装PowerShell-v7.6.4(附安装包powershell-7.6.4-osx-arm64.pkg)
macos·自动化·跨平台·shell·脚本·命令行·powershell
__zRainy__2 天前
解决pnpm v10+不自动构建
前端·pnpm·工程化
星辰即远方2 天前
天气预报总结
macos·ios·objective-c·cocoa
xixiaoyunya2 天前
Mac远程访问新范式:基于80KM穿云箭的内网穿透技术实践
macos
秋雨梧桐叶落莳2 天前
计算器仿写总结
学习·macos·ios·objective-c·cocoa
寒水馨3 天前
macOS下载、安装uv-0.12.0(附安装包uv-aarch64-apple-darwin.tar.gz)
python·macos·rust·项目管理·包管理器·astral·pip替代
寒水馨3 天前
macOS下载、安装protobuf-v35.1(附安装包protoc-35.1-osx-universal_binary.zip)
macos·google·grpc·序列化·protobuf·protoc·数据交换
寒水馨3 天前
macOS下载、安装ripgrep-15.2.0(附安装包ripgrep-15.2.0-aarch64-apple-darwin.tar.gz)
macos·正则表达式·rust·ripgrep·rg·命令行搜索·代码搜索