更新
保持 OpenClaw 为最新版本。
推荐:openclaw update
Section titled “推荐:openclaw update”最快更新的方法。它会检测您的安装类型(npm 或 git),获取最新版本,运行 openclaw doctor,并重启网关。
openclaw update要切换渠道或定位到特定版本:
openclaw update --channel betaopenclaw update --tag mainopenclaw update --dry-run # preview without applying有关渠道的语义,请参阅 开发渠道。
备选方案:重新运行安装程序
Section titled “备选方案:重新运行安装程序”curl -fsSL https://openclaw.ai/install.sh | bash添加 --no-onboard 以跳过新手引导。对于源码安装,请传递 --install-method git --no-onboard。
备选方案:手动 npm 或 pnpm
Section titled “备选方案:手动 npm 或 pnpm”npm i -g openclaw@latestpnpm add -g openclaw@latest自动更新功能默认关闭。在 ~/.openclaw/openclaw.json 中启用:
{ update: { channel: "stable", auto: { enabled: true, stableDelayHours: 6, stableJitterHours: 12, betaCheckIntervalHours: 1, }, },}| 渠道 | 行为 |
|---|---|
stable | 等待 stableDelayHours,然后对 stableJitterHours 应用确定性抖动(分阶段推出)。 |
beta | 每隔 betaCheckIntervalHours 检查一次(默认:每小时)并立即应用。 |
dev | 不自动应用。手动使用 openclaw update。 |
网关还会在启动时记录更新提示(使用 update.checkOnStart: false 禁用)。
固定版本 (npm)
Section titled “固定版本 (npm)”npm i -g openclaw@<version>openclaw doctoropenclaw gateway restart提示:npm view openclaw version 显示当前发布的版本。
固定提交 (源码)
Section titled “固定提交 (源码)”git fetch origingit checkout "$(git rev-list -n 1 --before=\"2026-01-01\" origin/main)"pnpm install && pnpm buildopenclaw gateway restart要返回最新版本:git checkout main && git pull。
如果您遇到了问题
Section titled “如果您遇到了问题”- 再次运行
openclaw doctor并仔细阅读输出。 - 检查:故障排除
- 在 Discord 提问: https://discord.gg/clawd