A technical note for developers writing opencode plugins. It describes how plugin slash-command output works, what the relevant upstream code does, and the observable effect on plugins that try to display output without invoking the model. It sticks to verifiable behavior and cites the upstream commits/PRs; it does not speculate about anyone's intent.
macOS 26.3.1 (Apple Silicon) workstation configuration. Everything is installed via Homebrew 5.1.0 unless noted otherwise.
The default macOS command-line tools were designed decades ago and show their age. They produce dense, uncolored output, ignore modern conventions like .gitignore, and lack features developers now take for granted (syntax highlighting, git awareness, fuzzy search). This setup replaces them with modern alternatives — mostly written in Rust — that are faster, produce more readable output, and work the way you'd expect in a git-centric workflow. Every replacement is aliased to the original command name so muscle memory carries over.
| Tool | Replaces | Why |
|---|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| --- policy.json 2013-05-22 04:29:47.939198317 +0000 | |
| +++ policy.json.dpkg-dist 2013-05-20 05:02:36.000000000 +0000 | |
| @@ -1,5 +1,9 @@ | |
| { | |
| "admin_required": [["role:admin"], ["is_admin:1"]], | |
| + "owner" : [["user_id:%(user_id)s"]], | |
| + "admin_or_owner": [["rule:admin_required"], ["rule:owner"]], | |
| + | |
| + "default": [["rule:admin_required"]], |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/usr/bin/python | |
| import libvirt | |
| import os | |
| import sys | |
| import time | |
| import uuid | |
| try: | |
| instance_name = sys.argv[1] |