English | 简体中文
opencode-xk is a public maintenance fork of OpenCode. It keeps upstream attribution and license intact while shipping a separate local binary line focused on workflow stability, session recovery, CLI/TUI responsiveness, multi-window behavior, and low-risk performance fixes.
This is not the official OpenCode project. Use the upstream repository for official releases, npm packages, documentation, and support.
- Stabilizes session, workflow, recovery, retry, task, and subagent behavior.
- Improves CLI/TUI prompt submission, Enter handling, skill invocation, and long-output rendering.
- Keeps local
XK-*binary builds isolated from the official self-update path. - Cherry-picks small upstream fixes when they are safe for this fork.
- Maintains changes that may be split into small upstream pull requests later.
opencode-xkreleases are GitHub binary releases only.- npm publishing is intentionally disabled for this fork.
- Binary versions use the local
XK-*line, for exampleXK-2.0.0. - Official
opencodepackages and update feeds are not used forXK-*builds.
bun install
OPENCODE_VERSION="XK-2.0.0" bun run build:xkThe build script requires OPENCODE_VERSION=XK-* outside the official upstream repository. This prevents accidental official-version builds from the fork.
After building, install the native binary into the local version directory and point opencode-xk at it:
mkdir -p "$HOME/.opencode/versions/XK-2.0.0/bin"
cp "packages/opencode/dist/opencode-linux-x64/bin/opencode" "$HOME/.opencode/versions/XK-2.0.0/bin/opencode"
chmod +x "$HOME/.opencode/versions/XK-2.0.0/bin/opencode"
ln -sfn "$HOME/.opencode/versions/XK-2.0.0/bin/opencode" "$HOME/.opencode/bin/opencode-xk"
opencode-xk --versionUse the platform-specific artifact path produced under packages/opencode/dist/ when building on macOS or Windows.
bun install
bun run --cwd packages/opencode typecheck
bun test --cwd packages/opencode test/cli/tui/prompt-submit-request.test.ts test/cli/tui/textarea-keybindings.test.tsTests must be run from package directories such as packages/opencode, not from the repository root.
Changes intended for official OpenCode should be split into small upstream-focused pull requests:
- no
XK-*versioning - no fork release policy
- no fork branding
- no local workflow rules
- one behavior fix per PR with targeted tests
Good upstream candidates include CLI prompt submission fixes, task/subagent hardening, session recovery edge cases, tool boundary checks, and small performance fixes.
This fork preserves the upstream MIT license. See LICENSE.