Plugins and Key Commands
Extend Hive with startup programs, event handlers, actions, custom shortcuts, and sidebar metadata.
Hive plugins are programs it can run at daemon startup, in response to events, or when you invoke an action. Key commands let you launch your own shell commands or plugin actions from the multiplexer.
Install a plugin
Install from a Git repository or a local directory. Hive shows the plugin’s commands and when they will run, the capabilities it requires and may ask for, what it adds to the UI, and whether it can run sandboxed, then asks for confirmation:
hive plugin install https://github.com/example/hive-pr-statushive plugin install ./pr-status --ref v0.1.0Accepting grants the plugin’s required capabilities. Each plugin reaches Hive only through its own socket, where every call is checked against those capabilities. Unless it runs under strict isolation, its process still has your user’s access to files and network, so review the trust preview. For automation, --yes accepts the install prompt.
Catalog plugins can be found and installed by ID. Updates verify the published release checksum and preserve the last installed release for rollback; plugin data remains in its managed data directory:
hive plugin search editorhive plugin install hive-explorerhive plugin update hive-explorerhive plugin rollback hive-explorerFor scripts, pass --yes to accept the install or update preview. Without a
terminal or --yes, Hive declines the operation. Registry outages do not
disable local linking or direct Git installation.
Scaffold and check a plugin locally before submitting it:
hive plugin init my-pluginhive plugin validate ./my-pluginThe registry governance guide covers submissions, ownership transfers, moderation reports, and appeals.
Use link for local development without copying the plugin:
hive plugin link ./my-pluginPlugin manifest
Each plugin directory contains hive-plugin.toml. A minimal example:
api = 1id = "pr-status"name = "PR status"version = "0.1.0"description = "Shows pull request information in the sidebar."platforms = ["darwin", "linux"]
[permissions]required = ["hive.read", "hive.write"]optional = ["network"][permissions.reasons]network = "fetch pull request status"
[[startup]]command = ["./pr-status.sh", "watch"]restart = true
[[actions]]id = "refresh"title = "Refresh PR status"command = ["./pr-status.sh", "once"]timeout = "2m"
[[events]]on = "worktree.created"command = ["./on-worktree.sh"]
[[contributes.cards]]id = "pr"title = "Pull request"scope = "environment"api = 1 pins the manifest to Plugin API; manifests without it run as legacy plugins that hold every capability and cannot contribute UI. Startup entries run while the daemon is running. Actions run when selected from Hive, the plugin palette, or hive plugin run, and async = true returns at once with a run ID. Events can match an event name such as worktree.created or a prefix such as agent.. A plugin runs up to four event commands at once by default; set event_concurrency (1–16) to change that, where 1 handles events strictly in order. [contributes] declares sidebar cards, tab-bar indicators, contextual actions, palette entries, and links that Hive draws from data.
Commands run in the plugin directory. Executables prefixed with ./ are resolved there; other commands use PATH. Hive passes plugin context as JSON on stdin and through HIVE_PLUGIN_CONTEXT. Other variables include HIVE_PLUGIN_ID, HIVE_PLUGIN_DIR, HIVE_PLUGIN_API, HIVE_PLUGIN_CAPABILITIES, HIVE_PLUGIN_DATA, HIVE_PLUGIN_CONFIG, HIVE_PLUGIN_CACHE, HIVE_BIN, HIVE_SOCKET_PATH, HIVE_SESSION, and HIVE_HOME. The Plugin API reference documents the full context, capabilities, events, and contribution limits.
Manage and inspect plugins
hive plugin listhive plugin info pr-statushive plugin run pr-status refreshhive plugin logs pr-status -fhive plugin disable pr-statushive plugin enable pr-statushive plugin uninstall pr-statusCheck health, permissions, and settings:
hive plugin doctor pr-status # manifest, API version, permissions, sandbox, live healthhive plugin reload pr-status # restart from its manifest, grants, and settingshive plugin grant pr-status network # grant an optional capabilityhive plugin revoke pr-status networkhive plugin config pr-status --set name=valuehive plugin contributions # list UI contributions and their keyshive plugin cancel pr-status <run> # stop a running actionhive plugin export -o plugins.tar.gz # back up sources, grants, and settingshive plugin import plugins.tar.gzPlugins move through starting, ready, degraded, failed, and disabled. A startup command that keeps crashing is given up on after [plugins] restart_limit failures within restart_window; hive plugin reload starts it afresh. Global policy lives in [plugins]: allow and deny capabilities for every plugin, isolation = "auto" | "standard" | "strict", and hidden contributions. See the Configuration Reference.
Installed plugins live under ~/.hive/plugins/ and are shared across local Hive sessions. Settings live in ~/.hive/plugins/.config/<id>/ and data in ~/.hive/plugins/.data/<id>/; both survive updates and uninstalls unless you pass --delete-data. Plugin output is written to ~/.hive/logs/plugins/<id>.log. To install a specific revision, use --ref and review the recorded commit.
Bind a key to a command
Add a [[keys.command]] block to Hive’s configuration:
[[keys.command]]keys = "g"type = "popup"command = "lazygit"title = "lazygit"Supported types are popup (temporary overlay), pane (new split), shell (background command with its last line shown), and plugin_action. Set mode = "terminal" to bind a command without the prefix; the default is prefix mode. Commands run on the machine whose workspace is currently shown.
hive config reset-keys restores built-in bindings but keeps custom key commands.
Sidebar tokens and status bar
Commands and plugins can add temporary labels to an environment or pane:
hive pane report-metadata --token tests=40/40 --title reviewerhive env report-metadata app --token pr="#12 open ✓" --ttl 10mhive metadataTokens expire after their TTL (30 minutes by default, up to 7 days) and are not kept across daemon restarts. The status bar can display text, the time, host name, or a command’s first line; configure [[ui.status_right]] in config.toml.