install --update.
Usage
How It Works
Theupdate command:
- Reads the lock file —
.opencode/agents/.manifest-lock.json - Computes hashes — SHA-256 of each installed agent file
- Compares hashes — Identifies agents where current hash ≠ lock hash
- Reinstalls outdated — Downloads and overwrites mismatched agents (forced)
- Updates lock — Records new hashes and timestamps
Hashes are computed after permission modifications, so changing permissions via CLI flags will not trigger reinstall.
When to Use
Useupdate when:
- The registry manifest has been updated (new agent versions)
- You manually edited an agent file and want to restore the original
- You suspect local modifications and want to sync with upstream
Lock File
The lock file (.opencode/agents/.manifest-lock.json) tracks:
- sha256 — Content hash for change detection (not security)
- installedAt — ISO 8601 timestamp of first install
- updatedAt — ISO 8601 timestamp of last update
Flags
Preview which agents would be updated without downloading or writing files.
Permission Flags
All permission flags from install are supported:--permissions <preset>— Apply permission preset (strict, balanced, permissive, yolo)--yolo— Allow all permissions (requires CONFIRM)--permission-override <spec>— Override specific permissions--save-permissions— Save permission choices for future installs--no-saved-permissions— Ignore saved preferences--no-interactive— Skip interactive prompts
Examples
Check for updates
Dry-run update
Update with custom permissions
Comparison with install —update
These commands are identical:- Detect outdated agents via hash comparison
- Reinstall only mismatched agents
- Force overwrite (ignore existing files)
- Update lock file timestamps
Exit Codes
| Code | Meaning |
|---|---|
0 | All outdated agents updated successfully, or no updates needed |
1 | One or more agents failed to update |
What Gets Updated
- Agent file — Downloaded from GitHub and overwritten
- Lock entry — New hash and
updatedAttimestamp - Permissions — Applied from CLI flags or saved preferences
The
installedAt timestamp is preserved during updates.