aff863c69f
An older Claude Code has no -y on `plugin install|update` and exits with "error: unknown option '-y'", so the dashboard's Update now chain failed at its plugin_update step (and so did Update all, the plugin buttons and the superpowers auto-install). Those versions also predate the confirmation prompt -y answers, so every wrapper now retries the same argv without it when, and only when, the CLI rejects the flag. /agenthub-update, which the failure message points users to, falls back the same way.
52 lines
2.1 KiB
Markdown
52 lines
2.1 KiB
Markdown
---
|
|
description: Pull the latest agenthub plugin version and refresh the dashboard runtime
|
|
---
|
|
|
|
Pull the newest `agenthub` release from its marketplace, then reinstall the runtime
|
|
dependencies and restart the dashboard server against it. Use this to get a new
|
|
dashboard build, or when `/agenthub-doctor` reports missing dependencies or a dead
|
|
server.
|
|
|
|
First, find which marketplace this install's `agenthub` came from and pull the
|
|
latest version into the plugin cache:
|
|
|
|
```bash
|
|
INSTALLED=$(claude plugin list 2>/dev/null | grep -o 'agenthub@[^ ]*' | head -1)
|
|
MARKETPLACE="${INSTALLED#agenthub@}"
|
|
if [ -z "$MARKETPLACE" ]; then
|
|
echo "agenthub is not installed as a plugin (checkout install?) - nothing to update this way."
|
|
else
|
|
claude plugin marketplace update "$MARKETPLACE"
|
|
# An older Claude Code has no `-y` (and no prompt for it to answer).
|
|
claude plugin update "agenthub@$MARKETPLACE" -y 2>/dev/null ||
|
|
claude plugin update "agenthub@$MARKETPLACE"
|
|
fi
|
|
```
|
|
|
|
That downloads the new version into `~/.claude/plugins/cache/` but does not
|
|
take effect in *this* session — Claude Code only re-resolves `${CLAUDE_PLUGIN_ROOT}`
|
|
on `/reload-plugins` (a REPL-only action, not scriptable from a command). Say
|
|
so plainly: **tell the user to run `/reload-plugins` now**, then either
|
|
re-run `/agenthub-update` (this time the bootstrap step below runs against the new
|
|
version) or just start a new session — `plugin-bootstrap.js` compares the
|
|
recorded state against the current plugin version on every `SessionStart` and
|
|
rebuilds automatically if they differ.
|
|
|
|
Then, whether or not a plugin update was just pulled, refresh the runtime
|
|
against whatever `${CLAUDE_PLUGIN_ROOT}` currently resolves to. This stops the
|
|
running dashboard server before starting the new one. Say so, then run:
|
|
|
|
```bash
|
|
node "${CLAUDE_PLUGIN_ROOT}/scripts/plugin-bootstrap.js" --force
|
|
```
|
|
|
|
It runs in the foreground and can take a few minutes on a cold cache. When it
|
|
finishes, verify:
|
|
|
|
```bash
|
|
node "${CLAUDE_PLUGIN_ROOT}/scripts/plugin-doctor.js"
|
|
```
|
|
|
|
Report the final state in a few lines. If the bootstrap failed, quote the
|
|
decisive line from `~/.claude/agenthub/runtime/bootstrap.log`.
|