Bun 备忘清单 === 这是一份 [`Bun`](https://bun.sh/) 软件包管理器备忘单,其中列出了 `Bun` 常用命令使用清单 入门 --- ### 安装 Bun ```bash curl -fsSL https://bun.sh/install | bash ``` ### Bun 与 npm/Yarn 命令比较 npm/Yarn | Bun | 说明 :- | :- | :- `npm install`, `yarn add` | `bun add` | 安装依赖 `npm init`, `yarn init` | `bun init` | 创建 `package.json` 文件 `npm install -g`, `yarn global add` | `bun global add` | 全局安装包 `npm run`, `yarn run` | `bun run` | 运行脚本 `npm uninstall`, `yarn remove` | `bun remove` | 移除包 `npm update`, `yarn upgrade` | `bun upgrade` | 更新包 `npm cache clean`, `yarn cache clean` | `bun cache clean` | 清理缓存目录 ### 创建项目 ```bash bun create