The docs said ~/.hanzo-bot/hanzo-bot.json (and ~/.hanzo-bot-<profile>, hanzo-bot.plugin.json), which nothing reads: src/config/paths.ts resolves ~/.bot, bot.json and ~/.bot-<profile>, and plugins ship bot.plugin.json. Every such path in docs/ now names what the code opens. Co-authored-by: Hanzo Dev <[email protected]>
2.9 KiB
summary, read_when, title
| summary | read_when | title | ||
|---|---|---|---|---|
| CLI reference for `hanzo-bot plugins` (list, install, uninstall, enable/disable, doctor) |
|
plugins |
hanzo-bot plugins
Manage Gateway plugins/extensions (loaded in-process).
Related:
- Plugin system: Plugins
- Plugin manifest + schema: Plugin manifest
- Security hardening: Security
Commands
hanzo-bot plugins list
hanzo-bot plugins info <id>
hanzo-bot plugins enable <id>
hanzo-bot plugins disable <id>
hanzo-bot plugins uninstall <id>
hanzo-bot plugins doctor
hanzo-bot plugins update <id>
hanzo-bot plugins update --all
Bundled plugins ship with HanzoBot but start disabled. Use plugins enable to
activate them.
All plugins must ship a bot.plugin.json file with an inline JSON Schema
(configSchema, even if empty). Missing/invalid manifests or schemas prevent
the plugin from loading and fail config validation.
Install
hanzo-bot plugins install <path-or-spec>
hanzo-bot plugins install <npm-spec> --pin
Security note: treat plugin installs like running code. Prefer pinned versions.
Npm specs are registry-only (package name + optional version/tag). Git/URL/file
specs are rejected. Dependency installs run with --ignore-scripts for safety.
If a bare install spec matches a bundled plugin id (for example diffs), HanzoBot
installs the bundled plugin directly. To install an npm package with the same
name, use an explicit scoped spec (for example @scope/diffs).
Supported archives: .zip, .tgz, .tar.gz, .tar.
Use --link to avoid copying a local directory (adds to plugins.load.paths):
hanzo-bot plugins install -l ./my-plugin
Use --pin on npm installs to save the resolved exact spec (name@version) in
plugins.installs while keeping the default behavior unpinned.
Uninstall
hanzo-bot plugins uninstall <id>
hanzo-bot plugins uninstall <id> --dry-run
hanzo-bot plugins uninstall <id> --keep-files
uninstall removes plugin records from plugins.entries, plugins.installs,
the plugin allowlist, and linked plugins.load.paths entries when applicable.
For active memory plugins, the memory slot resets to memory-core.
By default, uninstall also removes the plugin install directory under the active
state dir extensions root ($BOT_STATE_DIR/extensions/<id>). Use
--keep-files to keep files on disk.
--keep-config is supported as a deprecated alias for --keep-files.
Update
hanzo-bot plugins update <id>
hanzo-bot plugins update --all
hanzo-bot plugins update <id> --dry-run
Updates only apply to plugins installed from npm (tracked in plugins.installs).
When a stored integrity hash exists and the fetched artifact hash changes,
HanzoBot prints a warning and asks for confirmation before proceeding. Use
global --yes to bypass prompts in CI/non-interactive runs.