Skip to content

fix(claude-code-docs): vendor plugin into the marketplace - #297

Merged
amondnet merged 4 commits into
mainfrom
amondnet/vendor-claude-code-docs
Nov 2, 2026
Merged

amondnet merged 4 commits into
mainfrom
amondnet/vendor-claude-code-docs

Conversation

@amondnet

@amondnet amondnet commented Oct 30, 2026 •

Copy link
Copy Markdown
Contributor

Summary

This moves the claude-code-docs plugin code into this marketplace, so installing it no longer clones the 44 MB pleaseai/claude-code-docs repo. That also covers the plugins that pull it in as a dependency. This is the claude-code-docs follow-up that chatbot-pf/engineering-standards#2681 left to this repo.

Why

  • On Claude Code 2.1.310, a remote-source plugin is cloned again on every install, even when pinned to a commit (measured in chatbot-pf/engineering-standards#2679).
  • context@passionfactory declares claude-code-docs@pleaseai as a dependency, and 9 passionfactory plugins depend on context. So every one of those installs paid for this clone. After #2681 removed the other clones, the remaining ~5 s of the tidy-first install was almost entirely this one.
  • The upstream repo is 44 MB because of docs/ and llms-full.txt (10 MB). The plugin itself is about 10 KB: one skill and one hook. The skill already resolves the docs through ask src github:pleaseai/claude-code-docs, so the installed plugin never reads docs/.

Changes

  • plugins/claude-code-docs/: copied skills/, hooks/ and .claude-plugin/ byte-for-byte from pleaseai/claude-code-docs@72ef109, including execute bits. Nothing else was copied.
  • .claude-plugin/marketplace.json: source changed from github: pleaseai/claude-code-docs to ./plugins/claude-code-docs. The plugin ID (claude-code-docs@pleaseai) is unchanged, so the dependencies declarations in passionfactory keep working.
  • bun scripts/cli.ts multi-format: generated the Codex, Cursor and Antigravity manifests and updated the Codex/Cursor marketplaces. I reverted the unrelated repo-wide churn it produced, including a csp-mcp entry missing from the Codex marketplace since feat(marketplace): add csp-mcp plugin #288 and untracked portone MCP files. This PR only contains the claude-code-docs changes.
  • release-please: registered plugins/claude-code-docs at 1.0.0, with all four version-bearing manifests as extra-files. This is a fix: commit, so the next release bumps it to 1.0.1. That bump is required: #2681 found that changing the source while keeping the same version does not update existing installs.
  • README: moved the entry from External to Built-in Plugins.

pleaseai/claude-code-docs stays as the docs mirror; nothing changes there in this PR.

Related issue

Follow-up to chatbot-pf/engineering-standards#2679 / chatbot-pf/engineering-standards#2681.

Checklist

  • PR title follows Conventional Commits
  • Tests added or updated, and the suite passes: hooks/rewrite-docs-url.test.sh passes 13/13 in its new location. No other tests were affected.
  • Lint/format pass (bun run lint)
  • Documentation updated if behavior changed (README)
  • No breaking change

Validation

claude plugin validate .claude-plugin/marketplace.json reports the same errors as main. They were already there and this PR does not touch them:

  • The claude-code-docs and claude-md-management names are now reserved. Renaming would change the plugin ID that passionfactory depends on, so it needs its own decision.

claude plugin validate plugins/claude-code-docs also flagged that ${CLAUDE_PLUGIN_ROOT} was unquoted in the upstream hooks/hooks.json. Fixed in 7c18b6b: the command is now bash "${CLAUDE_PLUGIN_ROOT}/hooks/rewrite-docs-url.sh", and the Antigravity hooks.json was regenerated. Run from a plugin root containing a space, the quoted command rewrites the URL correctly, while the old one failed with No such file or directory. The hook test still passes 13/13.

After merge

  • Confirm the release PR bumps claude-code-docs to 1.0.1, and that plugin update moves an existing install to the local copy.
  • Install context@passionfactory with a fresh CLAUDE_CONFIG_DIR and check the debug log has no Cloned repository line for claude-code-docs.

Summary by cubic

Vendors the claude-code-docs plugin into this marketplace so installs no longer clone the 44 MB pleaseai/claude-code-docs repo. Plugin code (skills/, hooks/, .claude-plugin/) is copied byte-for-byte from upstream, and the marketplace source now points at ./plugins/claude-code-docs. The upstream repo stays as the docs mirror since the skill resolves docs through ask src. The hook command now quotes ${CLAUDE_PLUGIN_ROOT} so it runs correctly when the install path contains a space.

Migration

  • The plugin ID is unchanged, so passionfactory plugin dependencies keep resolving.
  • This is a fix: commit, so the next release-please release bumps the plugin to 1.0.1; that bump is required for existing installs to pick up the local copy.

Written for commit 4aee077. Summary will update on new commits.

Turn on auto-fix

Move the plugin code (skills/, hooks/, .claude-plugin/) from
pleaseai/claude-code-docs@72ef109 into plugins/claude-code-docs and
switch the marketplace source to the local path. Installing the plugin,
or any plugin that depends on it, no longer clones the 44 MB docs
mirror. The skill already resolves the docs through `ask src`, so the
mirror repo stays as is.
@gemini-code-assist

Copy link
Copy Markdown
Contributor

Warning

You have reached your daily quota limit. Please wait up to 24 hours and I will start processing your requests again!

@vercel

vercel Bot commented Oct 30, 2026 •

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated
claude-code-plugins Ready Ready Preview Nov 2, 2026 1:28am UTC

Request Review

@codacy-production

Copy link
Copy Markdown

Up to standards ✅

🟢 Issues 0 issues

Results:
0 new issues

View in Codacy

NEW Get contextual insights on your PRs based on Codacy's metrics, along with PR and Jira context, without leaving GitHub. Enable AI reviewer
TIP This summary will be updated as you push new changes.

@github-actions

Copy link
Copy Markdown

🔍 Tessl Skill Review

plugins/claude-code-docs/skills/claude-code-docs/SKILL.md

score

A lean, highly actionable procedure: every step is an executable command with explicit fallback conditions, grounding/citation rules, and a terminal honesty checkpoint. The only improvement is trimming the redundant 'ask search' alternative in step 2, which is the sole conciseness deduction.

Validation

  • ⚠️ frontmatter_unknown_keys — Unknown frontmatter key(s) found; consider removing or moving to metadata
Full review details

Validation Checks

15/16 checks passed.

Review Details

Dimension Score Detail
conciseness ████░ 4/5 Nearly all prose is operational — fallback conditions, the llms.txt manifest tip, grounding rules — with no explanation of concepts Claude already knows. The one trimmable redundancy is the 'Or equivalently via ask (requires csp on PATH)' block, which duplicates the csp search command already given (and still requires csp on PATH). This fits 'efficient; minor instances of over-explanation that could be trimmed' rather than the 5 anchor's 'every token earns its place'.
actionability █████ 5/5 Every step is a copy-paste-ready command: 'DOCS="$(ask src github:pleaseai/claude-code-docs)/docs"', 'csp search "$question" "$DOCS" --content docs --top-k 8', the npx/bunx variants, 'grep -ril "" "$DOCS"', and the WebFetch fallback with a concrete URL and the '.md' rewrite convention. The common cases (CLI missing, csp missing, fully offline) are each covered by a specific executable alternative, matching the 5 anchor.
workflow clarity █████ 5/5 Four clearly sequenced, numbered steps with explicit fallback conditions at each branch ('If the ask CLI is not on PATH', 'If csp is not on PATH', 'If that fails too', 'Only fall back to step 4 (WebFetch) when neither works') and terminal checkpoints ('Ground every claim in what the pages actually say', 'If the docs do not answer the question, say so explicitly — do not fill gaps from memory'). This is a read-only, single-purpose lookup task, so the destructive/batch validation cap does not apply, and the fallback chain plus honesty rule provide the error recovery the 5 anchor requires.
progressive disclosure █████ 5/5 The body is compact (~45 non-blank lines), organized into clearly signaled sections (### 1–4), with no bundle files and nothing inlined that belongs in a separate file; external pointers ($DOCS/../llms.txt manifest, the docs mirror, the WebFetch manifest) are one level deep and clearly labeled. Under the rubric's simple-skill guidance this warrants a 5 on well-organized sections alone.

Description Review

Dimension Score Detail
specificity ████░ 4/5 Concrete actions are named — 'Answer questions about Claude Code (features, hooks, plugins, skills, MCP, Agent SDK, settings, CLI) from the official docs' plus 'Uses the ask CLI to resolve a version-pinned local mirror and csp for semantic search, falling back to grep and WebFetch' — with comprehensive topic coverage. It falls short of the 5 anchor because the user-facing capability is essentially a single action (answering questions); the remaining specifics describe internal mechanism rather than additional distinct capabilities, which fits 'lists several specific actions; minor gaps'.
completeness █████ 5/5 The what is explicit ('Answer questions about Claude Code ... from the official docs. Uses the ask CLI ... falling back to grep and WebFetch') and the when is explicit with concrete trigger phrases ('Use when the user asks how Claude Code works, what a configuration field does, or whether Claude Code supports something'). Both are clearly and explicitly answered, matching the 5 anchor exactly; the 'Use when' clause is present so no cap applies.
trigger term quality █████ 5/5 The description includes the natural phrasings users actually say — 'how Claude Code works', 'what a configuration field does', 'whether Claude Code supports something' — alongside domain keywords ('hooks', 'plugins', 'skills', 'MCP', 'settings', 'CLI', 'official docs'). Coverage is comprehensive for this domain with no commonly used synonym missing, matching the 5 anchor rather than the 4 anchor's 'a few natural terms missing'.
distinctiveness conflict risk ████░ 4/5 The description is scoped to a clear niche — questions about Claude Code answered from official docs — with distinct triggers, but 'MCP' and 'Agent SDK' are trigger terms shared with closely related API-documentation skills, leaving minor overlap risk. This fits the 4 anchor ('mostly distinct; minor overlap risk with closely related skills') better than the 5 anchor's 'minimal conflict risk'.

To improve your score, point your agent at the Tessl optimization guide. Need help? Jump on our Discord.

Feedback

Report issues with this review at tesslio/skill-review, or send private feedback from your terminal with tessl feedback.

@amondnet
amondnet marked this pull request as ready for review October 30, 2026 06:47
@gemini-code-assist

Copy link
Copy Markdown
Contributor

Warning

You have reached your daily quota limit. Please wait up to 24 hours and I will start processing your requests again!

@chatgpt-codex-connector

chatgpt-codex-connector Bot commented Oct 30, 2026 •

Copy link
Copy Markdown

Codex Review Summary

This comment shows the latest Codex review activity on this pull request.

Review Status Commit Review trigger
📝 Code Review ✅ Completed 2026-10-30T06:50:36.756304Z 4a189f5 Draft marked ready
ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review" or "@codex security review".

Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings.

@greptile-apps

greptile-apps Bot commented Oct 30, 2026 •

Copy link
Copy Markdown

RetriggerView in GreptileConfidence Score: 5/5

[Medium impact] The PR appears safe to merge.

Summary

Moves claude-code-docs into the marketplace so installation no longer needs a separate clone.

  • The docs hook runs from plugin folders with spaces.
  • The marketplace installs Claude Code Docs from its own plugin folder.

Reviews (4) · Last reviewed commit: "docs(readme): list claude-code-docs unde..." · Reviewed by Greptile

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 4a189f543e

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

@cubic-dev-ai cubic-dev-ai Bot left a comment •

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

All reported issues were addressed across 15 files

Architecture diagram
sequenceDiagram
    participant User as Claude Code User
    participant CC as Claude Code CLI
    participant MP as Marketplace Registry (.claude-plugin/marketplace.json)
    participant Plugin as Vendored Plugin (plugins/claude-code-docs)
    participant Hook as PreToolUse Hook (rewrite-docs-url.sh)
    participant Web as WebFetch Tool
    participant Mirror as Docs Mirror (github:pleaseai/claude-code-docs)
    participant Ask as ask CLI

    Note over User,Ask: Plugin Installation Flow
    
    User->>CC: /plugin install claude-code-docs@pleaseai
    CC->>MP: Resolve plugin source
    MP-->>CC: Local path: ./plugins/claude-code-docs
    CC->>Plugin: Load local plugin files (skills/, hooks/)
    Plugin-->>CC: Plugin manifest + hooks registered
    CC-->>User: Plugin installed (no remote clone)

    Note over User,Ask: Runtime: Docs Query Flow
    
    User->>CC: Ask question about Claude Code
    CC->>Plugin: Trigger skill
    Plugin->>Ask: ask src github:pleaseai/claude-code-docs
    Ask->>Mirror: Clone/resolve cached docs mirror (44 MB, first use only)
    Mirror-->>Ask: Docs root path
    Ask-->>Plugin: Local docs path
    
    alt ask CLI available
        Plugin->>Plugin: Search docs (csp/grep over mirror)
        Plugin-->>CC: Answer grounded in local docs
    else ask CLI unavailable
        Plugin->>Web: WebFetch llms.txt from code.claude.com
        Web->>Hook: PreToolUse interception
        Hook->>Hook: Rewrite docs URL to .md source
        Hook-->>Web: Updated URL (e.g., docs/en/agents.md)
        Web->>Mirror: Fetch markdown source
        Mirror-->>Web: Markdown content
        Web-->>Plugin: Docs content
        Plugin-->>CC: Answer grounded in fetched docs
    end

    Note over User,CC: Install in marketplace context
    User->>CC: /plugin install context@passionfactory
    CC->>MP: Resolve dependency chain
    MP-->>CC: claude-code-docs@pleaseai (local source)
    CC->>Plugin: Load local plugin (no git clone)
    CC-->>User: Context plugin ready
Loading

Reply with feedback, questions, or to request a fix.

Turn on auto-fix | Re-trigger cubic

Comment thread README.md Resolved
…ok command

An unquoted plugin root splits into several words when the install path
contains a space, so bash fails to find the script and the hook never
runs. The Antigravity hooks.json is regenerated by multi-format.
@pleaseai

pleaseai Bot commented Nov 2, 2026 •

Copy link
Copy Markdown
Contributor

✅ @amondnet님의 요청을 완료했습니다 (7s) —— View job


Acknowledged

Your comment reports a fix (4aee077, moving claude-code-docs@pleaseai into the # Built-in plugins install block) and doesn't ask for any further change. I made no code changes and did not re-check the README in this run.

The other review findings are already tracked in #301, so this PR stays a byte-identical move plus the quoting fix.

@amondnet
amondnet merged commit 63d9087 into main Nov 2, 2026
12 checks passed
@amondnet
amondnet deleted the amondnet/vendor-claude-code-docs branch November 2, 2026 01:29
@sonarqubecloud

sonarqubecloud Bot commented Nov 2, 2026

Copy link
Copy Markdown

This branch was successfully deployed

1 active deployment
Preview — 4aee0770 Deployed Nov 2, 2026 by vercel[bot]
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.

1 participant