opencode-plugin-hanHan bridge for OpenCode - enables Han's validation hooks and plugin ecosystem in OpenCode sessions
190
近 30 天 +1
45
近 7 天 7
50.4
生态多维模型
1 天前
2026-08-19
快速安装与配置
opencode.json写入当前项目的 opencode.json,只对这个仓库生效。
opencode.json
{
"$schema": "https://opencode.ai/config.json",
"plugin": ["opencode-plugin-han@0.2.0"]
}写入 ~/.config/opencode/opencode.json,对所有项目生效。
~/.config/opencode/opencode.json
{
"$schema": "https://opencode.ai/config.json",
"plugin": ["opencode-plugin-han@0.2.0"]
}若你要在本地改造这个插件,先装到项目里再从本地路径引用。
shell
pnpm add -D opencode-plugin-hanopencode 启动时会通过内嵌运行时自动加载 npm 依赖并缓存至本地目录,无需手动在全局环境执行安装。
Ship-ready code from your AI coding agent. 340 plugins for quality gates, tooling, memory, and specialized agents, so your AI writes code that's ready to merge.
Getting Started
Two commands. That's it.
# 1. Install the CLI
curl -fsSL https://han.guru/install.sh | bash
# 2. Auto-detect and install plugins for your project
han plugin install --auto
Next time you use Claude Code, validation hooks run automatically when you finish a conversation.
Alternative Installation
# Homebrew (macOS/Linux)
brew install thebushidocollective/tap/han
How It Works
- Install - One command installs the CLI and auto-detects plugins for your stack
- Code - Claude writes code as usual. No workflow changes needed
- Validate - Stop hooks run automatically. Linters, formatters, type checkers, and tests are all verified
- Learn - Local metrics track success rates and calibrate confidence. Nothing leaves your machine
Plugin Categories
340 plugins across nine categories:
| Category | Description | Examples |
|---|---|---|
| Core | Essential infrastructure. Auto-installs the han binary, provides metrics and MCP servers | core, bushido |
| Language | Deep knowledge of a programming language | TypeScript, Rust, Python, Go, Ruby |
| Framework | Web, mobile, and backend framework expertise | React, Next.js, Django, Rails, Phoenix |
| Validation | Linters, formatters, and static analysis | Biome, ESLint, RuboCop, ShellCheck |
| Tool | Build systems, test runners, and dev utilities | Playwright, Jest, Pytest, Terraform |
| Integration | MCP servers for external services | GitHub, GitLab, Linear, Sentry |
| Discipline | Specialized AI agents for engineering domains | Security, accessibility, API design, architecture |
| Pattern | Methodologies and workflow practices | TDD, BDD, AI-DLC, git worktrees |
| Specialized | Domain-specific plugins that don't fit elsewhere | Android, iOS, embedded |
Browse all plugins at han.guru/plugins
Why It Works
- Smart Caching - Only runs validation when relevant files change. Native Rust hashing keeps it fast
- Local Metrics - Tracks task success and confidence calibration. All data stays on your machine
- Zero Config - Binary auto-installs on first session.
--autoflag detects your stack automatically - Any Stack - TypeScript, Python, Rust, Go, Ruby, Elixir. If there's a linter, there's a plugin
CLI Commands
# Install plugins
han plugin install # Interactive mode
han plugin install --auto # Auto-detect your stack
han plugin install <name> # Install specific plugin
# Manage plugins
han plugin search <query> # Search marketplace
han plugin uninstall <name> # Remove plugin
# Run hooks manually
han hook run <plugin> <hook> # Run a specific hook
han hook explain # Show configured hooks
# MCP server
han mcp # Start MCP server for natural language hook execution
Documentation
Full documentation at han.guru/docs
Contributing
See CONTRIBUTING.md for how to create new plugins.
License
MIT License - see LICENSE
Built by The Bushido Collective