feat: add HAX CLI Claude Code plugin + marketplace#28
Conversation
Make this repo a Claude Code plugin marketplace and ship the `hax` plugin so new users can discover, install, and drive the HAX CLI from inside Claude Code, reaching a live HAXsite in the browser on their first run. - .claude-plugin/marketplace.json: in-tool discovery (`/plugin marketplace add haxtheweb/create`) - plugins/hax/.claude-plugin/plugin.json: manifest - plugins/hax/hooks/: SessionStart hook auto-installs @haxtheweb/create when `hax` is missing (opt out with HAX_PLUGIN_NO_AUTOINSTALL=1) - plugins/hax/skills/hax/SKILL.md: onboarding-scoped CLI knowledge - plugins/hax/commands/: /hax:quickstart (golden path) plus site, webcomponent, serve, audit, publish Validated with `claude plugin validate` (plugin + marketplace). Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Brainstorm/requirements for the cross-tool (Claude Code + Codex) HAX onboarding layer. Documents the golden path, scope by platform, and the remaining Codex surface (AGENTS.md quickstart + custom prompt) deferred beyond the Claude plugin. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
|
All contributors have signed the CLA. Thank you! |
|
I have read the CLA Document and I hereby sign the CLA |
|
It looks like my Compound Engineering work pulled over, which is probably not necessary. I'd also like to run a more comprehensive set of tests off this fork/branch before this is merged, but I wanted to open it now in case there's any initial feedback. |
|
This appears to provide at least some level of overlapping capability with https://github.com/haxtheweb/claudehax though I believe your work is more developer focused (which we need!) and @djfusco is more 'get commands good enough so we can do education stuff' focused. Please review and correct me if I'm wrong. Thank you for the contribution in advance Rick :) |
There was a problem hiding this comment.
Pull request overview
Adds a Claude Code plugin marketplace entry for this repo and ships an initial hax plugin that helps users install and use the HAX CLI (@haxtheweb/create) via a SessionStart hook, an onboarding skill, and several /hax:* slash commands.
Changes:
- Adds a Claude Code plugin marketplace definition exposing the
haxplugin. - Introduces the
haxplugin manifest, SessionStart auto-install hook, and user-facing README. - Adds a HAX CLI skill plus slash-command docs for quickstart/site/webcomponent/audit/serve/publish workflows, and a requirements doc under
docs/.
Reviewed changes
Copilot reviewed 13 out of 13 changed files in this pull request and generated 4 comments.
Show a summary per file
| File | Description |
|---|---|
.claude-plugin/marketplace.json |
Registers the haxtheweb marketplace and exposes the hax plugin source path. |
plugins/hax/.claude-plugin/plugin.json |
Defines the hax plugin manifest metadata (name, version, links, keywords). |
plugins/hax/README.md |
Documents plugin purpose, installation via marketplace, and the /hax:quickstart golden path. |
plugins/hax/hooks/hooks.json |
Configures the SessionStart hook that runs the CLI availability/auto-install script. |
plugins/hax/hooks/scripts/ensure-hax.sh |
Implements best-effort detection/auto-install of @haxtheweb/create when hax is missing. |
plugins/hax/skills/hax/SKILL.md |
Provides the assistant with HAX CLI command-surface knowledge and HAX ecosystem conventions. |
plugins/hax/commands/quickstart.md |
Defines the /hax:quickstart workflow doc (scaffold site → serve). |
plugins/hax/commands/site.md |
Defines the /hax:site workflow doc for creating/administering HAXsites. |
plugins/hax/commands/webcomponent.md |
Defines the /hax:webcomponent workflow doc for scaffolding Lit/DDD components. |
plugins/hax/commands/audit.md |
Defines the /hax:audit workflow doc for DDD compliance auditing. |
plugins/hax/commands/serve.md |
Defines the /hax:serve workflow doc for running the HAXsite dev server. |
plugins/hax/commands/publish.md |
Defines the /hax:publish workflow doc for deploy/CI setup commands. |
docs/brainstorms/2026-06-29-hax-onboarding-plugins-requirements.md |
Captures v1 requirements and intended onboarding funnel/golden-path behavior. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
| # This hook never blocks the session: it always exits 0. Anything it prints on | ||
| # stdout is surfaced to Claude as session context so the assistant knows whether | ||
| # the CLI is ready. |
| # Human-facing progress goes to stderr; the result line goes to stdout/context. | ||
| echo "HAX CLI not found — installing @haxtheweb/create globally (one-time setup)…" 1>&2 | ||
| if npm install --global @haxtheweb/create >/dev/null 2>&1; then | ||
| ver="$(hax --version 2>/dev/null | head -n1 | tr -d '\r')" |
| 4. **Serve it.** `cd` into the new site folder and start the dev server in the | ||
| **background** (it is long-running and will not return): | ||
| `cd <name> && hax serve` | ||
| Read the startup output for the local URL (usually http://localhost, sometimes | ||
| a different port). |
| Guidance: | ||
| - Run from the root of a HAXsite. If the input names a site folder, `cd` into it first. | ||
| - `hax serve` is **long-running** — start it in the background so the session stays | ||
| responsive, then report the local URL to the user. | ||
| - If the current directory is not a HAXsite, say so and offer to create one with `/hax:site`. |
Description of Changes
Adds an official Claude Code plugin for the HAX CLI, and turns this repo into a Claude Code plugin marketplace so it can be installed directly.
What changed
.claude-plugin/marketplace.json) — registershaxthewebas a plugin marketplace exposing thehaxplugin.haxplugin (plugins/hax/):SessionStarthook checks forhaxonPATHand installs@haxtheweb/createglobally once if missing (opt out withHAX_PLUGIN_NO_AUTOINSTALL=1).haxskill — full command-surface knowledge (web components, sites, content/node ops, imports, skeletons, publishing) plus HAX conventions (JavaScript-only, DDD design tokens,haxProperties), loaded automatically when HAX comes up./hax:quickstart,/hax:site,/hax:webcomponent,/hax:audit,/hax:serve,/hax:publish.docs/) — the v1 requirements that scoped this work.Why this change was needed
Lets users install and drive the HAX CLI from inside Claude Code with a golden-path onboarding (
/hax:quickstart→ scaffold a HAXsite, serve it, hand back a live URL) instead of learning the CLI surface by hand.How to test
/plugin marketplace add haxtheweb/create(or a local checkout path)/plugin install hax@haxthewebhaxonPATH(or that it's skipped withHAX_PLUGIN_NO_AUTOINSTALL=1)./hax:quickstartand confirm it scaffolds a HAXsite, serves it, and returns a live URL.Notes
@haxtheweb/createpackage.