Ship OpenClaw as the seed for a self-updating copy under ~/.openclaw (#651)

A copy under /usr/lib/node_modules belongs to pacman, and upstream's updater refuses to write there, so neither `openclaw update` nor the Control UI's Update Gateway worked. The package now carries the release instead: the sha256-pinned npm tarball and the install-cli.sh that came in it, from which Omarchy seeds a copy under ~/.openclaw that updates itself.
This commit is contained in:
Spencer Bull authored and GitHub committed 2026-10-02 21:21:37 -05:00
1 parent 282bc1c43e
commit f6b9267b3b
2 files changed
+26 -47

No files matched your search

+10 -10
View File
@@ -1,17 +1,17 @@
post_install() {
printf "%s\n" \
"==> Install gateway service: openclaw gateway install --force" \
"==> Perform onboarding once: openclaw onboard"
"==> This is the release a self-updating OpenClaw starts from." \
"==> Set it up under ~/.openclaw: omarchy-install-openclaw-cli --now"
}
post_upgrade() {
# The gateway runs as a systemd user unit (openclaw-gateway.service in
# ~/.config/systemd/user), which a root pacman hook has no session bus
# to reach, so it cannot be restarted from here and keeps running the
# old code until the user restarts it.
# Earlier releases of this package were OpenClaw itself, under
# /usr/lib/node_modules/openclaw, and which of those a machine is leaving
# cannot be told from the version alone, since the upstream sync moves it.
# A root pacman hook has no session bus to move a user's OpenClaw, so
# Omarchy's migration does, and this says what happens either way.
printf "%s\n" \
"==> Restart the gateway to apply updates:" \
" openclaw gateway restart" \
"==> Run doctor to migrate configs, check gateway health, etc.:" \
" openclaw doctor"
"==> OpenClaw runs from ~/.openclaw and updates itself: openclaw update" \
"==> This package only sets the release new installs start from;" \
" omarchy update moves an OpenClaw still running from /usr there."
}