Skip to content

Add Han bridge for Google Antigravity IDE via MCP server#76

Open
jwaldrip wants to merge 2 commits intomainfrom
claude/add-antigravity-cli-ORGfc
Open

Add Han bridge for Google Antigravity IDE via MCP server#76
jwaldrip wants to merge 2 commits intomainfrom
claude/add-antigravity-cli-ORGfc

Conversation

@jwaldrip
Copy link
Collaborator

Summary

Adds a new Han bridge plugin that integrates Han's full plugin ecosystem (400+ skills, 25 disciplines, validation hooks) with Google Antigravity IDE via MCP server. Since Antigravity lacks lifecycle hooks like Claude Code/OpenCode, the bridge exposes Han capabilities as callable MCP tools instead.

Changes

  • New bridge plugin (plugins/bridges/antigravity/) with complete MCP server implementation:

    • index.ts - Main MCP server entry point with tool definitions for skills, disciplines, validation, sync, and context
    • discovery.ts - Plugin and hook discovery from Claude settings and marketplace
    • skills.ts - Skill discovery and loading from plugin directories
    • disciplines.ts - Agent discipline discovery and context building
    • executor.ts - Promise-based hook execution with parallel support
    • matcher.ts - Hook matching logic (tool filters, file filters, directory requirements)
    • formatter.ts - Structured result formatting for MCP responses
    • sync.ts - Sync skills to .agent/skills/ and generate .agent/rules/han-guidelines.md
    • context.ts - Guidelines and prompt context generation
    • cache.ts - Content-hash based hook execution caching
    • events.ts - JSONL event logging for Browse UI integration
    • types.ts - Shared type definitions
  • MCP Tools exposed:

    • han_skills - Browse and load 400+ coding skills
    • han_discipline - Activate specialized agent personas
    • han_validate - Run validation hooks on-demand (per-file or project-wide)
    • han_sync - Sync skills/rules to .agent/ for native discovery
    • han_context - Get session context (time, active discipline, stats)
  • Documentation:

    • README.md - Bridge architecture and usage guide
    • website/content/docs/installation/antigravity.md - Setup and tool reference
    • Updated website/content/docs/installation/index.md to mention Antigravity support
  • Integration:

    • Added to marketplace (marketplace.json)
    • Added plugin alias in packages/han/lib/plugin-aliases.ts
    • Updated navigation in website/content/docs/_nav.json

Type of Change

  • New feature
  • New plugin

Plugin Changes

Plugin category:

  • Integration - MCP servers for external services

Validation:

  • Plugin structure follows Han conventions (han-plugin.yml, .claude-plugin/plugin.json)
  • No hooks defined (bridge itself, not a validation plugin)

Testing

  • No automated tests needed - bridge is a new integration point that will be tested through Antigravity IDE usage
  • Manual testing will occur when users configure the MCP server in their Antigravity setup

Checklist

  • Code follows existing patterns (mirrors OpenCode bridge structure)
  • Self-review completed
  • Documentation added (README, installation guide, nav updates)
  • No new warnings

https://claude.ai/code/session_01QBTqGSaTzcQFrqsV76ARTD

Add MCP server bridge for Google Antigravity that exposes Han's plugin
ecosystem (400+ skills, 25 disciplines, validation hooks) as tools the
agent can call. Unlike the OpenCode bridge which hooks into JS events,
the Antigravity bridge uses MCP since Antigravity lacks lifecycle hooks.

Bridge provides five MCP tools:
- han_skills: browse/load coding skills on demand
- han_discipline: activate specialized agent personas
- han_validate: run validation hooks (per-file or project-wide)
- han_sync: copy skills/rules to .agent/ for native discovery
- han_context: get session state (time, active discipline, stats)

Also includes marketplace entries, plugin aliases, website docs, and
nav updates for the new bridge.

https://claude.ai/code/session_01QBTqGSaTzcQFrqsV76ARTD
@railway-app
Copy link

railway-app bot commented Mar 23, 2026

🚅 Deployed to the han-pr-76 environment in han-team-platform

4 services not affected by this PR
  • postgres
  • redis
  • website
  • api

Comment on lines +15 to +23
import {
readFileSync,
writeFileSync,
mkdirSync,
existsSync,
readdirSync,
rmSync,
copyFileSync,
} from "node:fs"
import { matchPostToolUseHooks, matchStopHooks } from "./matcher"
import { executeHooksParallel } from "./executor"
import { invalidateFile } from "./cache"
import { formatValidationResults, formatStopResults } from "./formatter"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants