Help us improve
Share bugs, ideas, or general feedback.
From runesmith-cc
Build the Claude Code monorepo head {PROJECT}.cc/ at the workspace root with normalized naming, auto-migration of detected repos, structured prompts for user input, comms folder, and optional repo create/clone via PAT auth. Use when the user says "bootstrap CC", "set up Claude Code", "create the cc folder", "init Claude Code workspace", "add a repo to CC", "clone repo into CC". Cowork builds; Claude Code never builds itself.
npx claudepluginhub runemarklabs/runesmith --plugin runesmith-ccHow this skill is triggered — by the user, by Claude, or both
Slash command
/runesmith-cc:bootstrap-ccThe summary Claude sees in its skill listing — used to decide when to auto-load this skill
Create the `<name>.cc/` monorepo head at workspace root. Cowork drives this; Claude Code consumes the result. Detects existing git repos and auto-migrates them. Uses structured prompts (never plain-text yes/no) for any user input.
Guides Next.js Cache Components and Partial Prerendering (PPR): 'use cache' directives, cacheLife(), cacheTag(), revalidateTag() for caching, invalidation, static/dynamic optimization. Auto-activates on cacheComponents: true.
Migrates code, prompts, and API calls from Claude Sonnet 4.0/4.5 or Opus 4.1 to Opus 4.5, updating model strings on Anthropic, AWS, GCP, Azure platforms.
Grills users relentlessly on plans or designs by interviewing branch-by-branch through decision trees to reach shared understanding. Use for stress-testing ideas or 'grill me'.
Share bugs, ideas, or general feedback.
Create the <name>.cc/ monorepo head at workspace root. Cowork drives this; Claude Code consumes the result. Detects existing git repos and auto-migrates them. Uses structured prompts (never plain-text yes/no) for any user input.
Idempotent. Safe to re-run.
agents/repo-bootstrapper.md - subagent for repo create/clone with PAT authlib/cc-workspace.md - canonical structurelib/comms-protocol.md - comms folder shapelib/comms-check.md - runs firstlib/credentials.md - .credentials resolution + GITHUB_PATlib/naming.md - kebab-case-lowercase normalization rulelib/agent-operating-principles.md - agent-ops principles applied to CC head CLAUDE.mdlib/code-analyzers.md - per-language analyzer registry for the deployed code-tech-debt skilltemplates/ directory (notably CLAUDE.parent.md which carries the agent-ops marker section)Every question to the user MUST be a structured prompt (the host client's multi-choice or form UI, e.g. AskUserQuestion in Cowork). Never ask freeform yes/no in plain chat text.
For values the user types (names, URLs): single-question form with a default pre-populated. Show the normalized form per lib/naming.md alongside the raw input so they can see and confirm.
Auto-decisions (no prompt needed):
<dir>/ containing .git/ at workspace root → auto-migrate into the CC head. No prompt.lib/naming.md). No prompt unless there are zero repos AND the workspace folder name normalizes to empty.See lib/comms-check.md.
Resolve workspace root (cwd or BOOTSTRAP_WORKSPACE env). No confirmation prompt - surface it in the upcoming plan.
For each subdir directly under workspace root, check for .git/. If found, that subdir is a git repo and will auto-migrate into the CC head.
Also detect:
<name>.cc/ (already canonical → idempotent re-init mode)claude-code/ (migrate to <name>.cc/)Per lib/naming.md:
Always show the resolved CC head name in the upcoming plan.
If user might add or create repos: read GITHUB_PAT from .credentials. If missing, mark repo operations as unavailable in the plan.
Use for:
claude-code/ to canonical <name>.cc/Do not use for:
/runesmith-sprint:enable/runesmith-devtools:plugin-builderPresent a structured summary:
Workspace root: <path>
CC head name: <normalized-name>.cc/ (from <source>: git repo "X" / workspace folder)
CC head state: fresh | legacy migration | re-init
Auto-migrating repos (no prompt):
- <repo-folder> → <name>.cc/<normalized-repo-folder>/
Files to create:
- CLAUDE.md, README.md, .claude-code-workspace, .claude/{...}, comms/{...}, .gitignore, .gitattributes
GitHub PAT: present | missing
Atlassian: not enabled (use /runesmith-sprint:enable after)
Single-pick structured prompt:
If migrating or filling into an existing folder where files might be overwritten:
archive/_pre-cc-bootstrap/<ISO timestamp>/
Copy current <name>.cc/ (or claude-code/, or each migrating repo) before any change.
claude-code/ → rename to <name>.cc/.<name>.cc/<normalized-repo-folder>/.claude-code/ move along when the parent renames.Per lib/cc-workspace.md, ensure these exist (do not clobber if user has customized):
| Path | Source template |
|---|---|
<name>.cc/CLAUDE.md | templates/CLAUDE.parent.md (token-substituted) |
<name>.cc/README.md | templates/README.md |
<name>.cc/.claude-code-workspace | templates/marker.json (token-substituted) |
<name>.cc/.claude/settings.json | ../guardrail/templates/project-settings.json (project-level guardrail scaffolding - additionalDirectories: [], empty allow/deny) |
<name>.cc/.claude/README.md | ../guardrail/templates/project-claude-readme.md (documents the boundary + escape-hatch usage) |
<name>.cc/.claude/settings.local.json | empty {} (gitignored) |
<name>.cc/.claude/skills/code-tech-debt/SKILL.md | ../../cc-skill-templates/code-tech-debt/SKILL.md (plugin-relative) |
<name>.cc/.claude/skills/code-tech-debt/lib/code-analyzers.md | ../../../lib/code-analyzers.md (plugin-relative) |
<name>.cc/.claude/commands/.gitkeep | empty |
<name>.cc/.claude/agents/.gitkeep | empty |
<name>.cc/.claude/hooks/.gitkeep | empty |
<name>.cc/comms/open/.gitkeep | empty |
<name>.cc/comms/archive/.gitkeep | empty |
<name>.cc/comms/README.md | templates/comms-README.md |
<name>.cc/.gitignore | templates/gitignore |
<name>.cc/.gitattributes | templates/gitattributes |
Guardrail nudge: after writing the project-level .claude/settings.json + .claude/README.md, check whether the user-level guardrail is installed (look for _runesmith_guardrail_marker in ~/.claude/settings.json / %USERPROFILE%\.claude\settings.json). If absent, surface this in the final report with a clear next step: "Run /runesmith-cc:guardrail install to enforce the project boundary at the harness level. Without it, the project-level settings are advisory only."
Token substitution:
{PROJECT} → resolved CC head name{ISO_TIMESTAMP} → now in ISO 8601Idempotent re-apply on existing CC head: if <name>.cc/CLAUDE.md already exists, do not overwrite. Instead, refresh the marker-bounded sections in place:
<!-- atlassian-section:start --> / <!-- atlassian-section:end --> - leave content alone (atlassian-enable owns it; bootstrap-cc only seeds empty markers on first write)<!-- agent-ops:start --> / <!-- agent-ops:end --> - replace content between markers with the current body from templates/CLAUDE.parent.md. If markers don't exist, append the full block before the closing comment.Never touch content outside any marker pair.
Every CC head ships with the following CC-side skill templates (callable from inside CC via slash commands):
code-tech-debt - repo-level dead-code / unused-export / unused-dep scanner. Per-language analyzers (TS, JS, Node, React, Next.js, Python out of the box; extensible via code-analyzers.md). Source: cc-skill-templates/code-tech-debt/SKILL.md in this plugin. The skill's lib (code-analyzers.md) is also copied into the deployed skill's own lib/ so it travels with the skill.Note: As of v0.8.0, the user-level CC project-boundary guardrail is installed via a one-shot installer script copied to the workspace root by /runesmith-cc:guardrail. It is no longer deployed as a CC-side skill template - CC's own permission system blocked the install of its own boundary, so the install path moved to a workspace-rooted PowerShell / bash script the user runs once per machine.
Sprint-specific skills (sprint-pull, ticket-document, blocker-write, ticket-done) are NOT deployed by bootstrap-cc - those are deployed by /runesmith-sprint:enable and only when the user opts into the Atlassian workflow.
Copy templates with token substitution where applicable. Do not clobber if the user has customized the deployed copy.
If a migrated repo lacks a top-level CLAUDE.md, drop a stub from templates/CLAUDE.repo.md (token-substituted: {PROJECT} → CC head name, {REPO_NAME} → normalized repo dir name). Do not commit; user reviews/edits first.
Write final .claude-code-workspace:
{
"project": "<normalized-cc-head-name>",
"initialized": "<ISO>",
"schemaVersion": 1,
"atlassianEnabled": false,
"atlassian": null,
"repos": [
{ "name": "<normalized-repo-dir>", "path": "./<normalized-repo-dir>", "migratedFrom": "<workspace-root>/<original-name>" }
]
}
After main bootstrap completes, present a structured single-pick prompt:
If user picks new or clone, delegate to the repo-bootstrapper agent with the relevant inputs. Form fields use structured prompts:
For new repo:
lib/naming.md and show preview)public | private.credentials if available)For clone:
After the agent returns, append the repo to .claude-code-workspace's repos[] and loop back to the add-or-skip prompt.
After all moves, scan migrated repos for:
.git/config containing literal credentials in remote URL (https://ghp_*@..., https://x-access-token:*@...).credentials, .env, secrets-named files at the repo rootSurface findings in the report as warnings with specific remediation commands.
✓ Claude Code workspace ready
Path: <workspace-root>/<name>.cc/
Drag this folder into Claude Code's "Open Folder":
<absolute path to <name>.cc/>
Migrated:
- <repo-folder>/ → <name>.cc/<normalized-repo-folder>/
Repos in CC head: <n>
Comms: <name>.cc/comms/ (open is gitignored, archive is committed)
⚠ Security review (if any)
- <name>.cc/<repo>/.git/config has a credential in the remote URL.
Rotate the token, then run:
git -C <path> remote set-url origin https://github.com/<owner>/<repo>.git
Next:
/runesmith-sprint:enable - wire Atlassian into this project (optional)
/runesmith-cc:bootstrap-cc - re-run any time to add more repos
If <name>.cc/ is already canonical:
lib/naming.md from the primary git repo (when present) or workspace folder name<name>.cc/ (lowercase, kebab-case)project, initialized, atlassianEnabled: false, repos[]/runesmith-sprint:enable's job).gitkeep so dirs exist in gitNo GITHUB_PAT, user wants to create repo: Surface a structured prompt to either skip repo creation, paste a PAT inline, or run /runesmith-core:setup first.
GitHub repo create 422 (name taken): Surface a structured prompt to either pick a different name or switch to clone mode.
Clone permission denied: Verify PAT scope (repo for private). Re-auth via /runesmith-core:setup.
<name>.cc/ exists with non-canonical content: Show diff, surface a structured choice: replace with template / preserve as-is / abort.
Multiple git repos and user can't pick primary: Default to alphabetically-first; surface that choice with structured prompt confirming.
Workspace folder name and all repo names normalize to empty: Surface a structured prompt asking user to type a name from scratch.