fix(plugins): retry claude plugin install|update without -y on an old CLI
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.
This commit is contained in:
@@ -17,7 +17,9 @@ 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"
|
||||
claude plugin update "agenthub@$MARKETPLACE" -y
|
||||
# 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
|
||||
```
|
||||
|
||||
|
||||
Reference in New Issue
Block a user