setuplisted
Install: claude install-skill haabe/mycelium
# Mycelium plugin setup
When this skill runs, do the following sequence. The skill is designed to be safe to re-run — every step is idempotent.
## Step 1: Detect initialization state
Check whether the user's project already has Mycelium project-state. The signal that initialization has happened:
```bash
test -f "$CLAUDE_PROJECT_DIR/.claude/diamonds/active.yml"
```
If the file exists, print:
> "Mycelium project state is already initialized. Existing canvas, diamonds, and memory are preserved. Run `/mycelium:diamond-assess` to see current state."
Then exit. Do NOT touch existing files.
If the file does NOT exist, continue to Step 2.
## Step 2: Create project-state directory structure
Resolve the project root: use `$CLAUDE_PROJECT_DIR` if set, else fall back to `pwd`. (Claude Code sets it automatically; non-Claude-Code agents may not.)
Create these directories in the user's project (using Bash `mkdir -p`):
```
<project_root>/.claude/canvas/
<project_root>/.claude/diamonds/
<project_root>/.claude/memory/
<project_root>/.claude/harness/
<project_root>/.claude/evals/
<project_root>/.claude/jit-tooling/
```
These directories hold project-specific state that the user's project owns and commits to git. Framework reference content (skills, hooks, theory gates) lives in the plugin cache and is not duplicated here.
A `.claude/state/` directory may also be present — that one is created and owned by Claude Code itself for runtime state (audit logs, etc.), not by Mycelium. Myc