setup-wiki

setup-wiki is a command for Claude Code from damusix/atomic-claude. It costs 43 tokens per session (4,711 once invoked), scanned A, original, MIT.

A command that prepares a repository for atomic-claude wiki conventions by checking its Git setup, ignore rules, documentation folders, and CLAUDE.md file.

In plain words
What is it for?
Use it to bootstrap or assess a repository's wiki arrangement, determine whether it belongs to a project or a wider realm, and propose only the required setup.
Why use it?
It shows what setup is missing without overwriting existing files or committing changes automatically.

Command for Claude Code

Written for Claude Code: SessionStart hook event. Also seen: reads .claude/ paths; mentions CLAUDE.md; mentions subagents.

Good fit Use it to bootstrap or assess a repository's wiki arrangement, determine whether it belongs to a project or a wider realm, and propose only the required setup.

Compare 6 commands from other repositories ↓
Install with agentmods
npx agentmods add commands/damusix/atomic-claude/setup-wiki
Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

Clone the repo
git clone --depth 1 https://github.com/damusix/atomic-claude

Made for: Claude Code.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for setup-wiki

README.md
[![agentmods](https://agentmods.dev/badge/commands/damusix/atomic-claude/setup-wiki/github.svg)](https://agentmods.dev/commands/damusix/atomic-claude/setup-wiki)
Your own site
<a href="https://agentmods.dev/commands/damusix/atomic-claude/setup-wiki"><img src="https://agentmods.dev/badge/commands/damusix/atomic-claude/setup-wiki/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for setup-wiki

Your own site · 80×15
<a href="https://agentmods.dev/commands/damusix/atomic-claude/setup-wiki"><img src="https://agentmods.dev/badge/commands/damusix/atomic-claude/setup-wiki.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 43 Only the description is in the session, so the agent can decide to use it. The body loads when it is invoked.
When invoked 4,711 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5.1 $0.00043 $0.04711
Opus 5.5 $0.00017 $0.01884
Sonnet 5.5 $0.00009 $0.00942
Haiku 4.5 $0.00004 $0.00471

Measured 12d ago against content hash 1aa1ff5af607, method: parsed. Prices are Anthropic first-party input rates as of 2026-10-07, from the pricing page.

Security

Grade A, and why

setup-wiki scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 12d ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

context/commands/setup-wiki.md · 378 lines

How it starts

The opening of the file, as written. The whole thing — 378 lines — stays where its author put it; the contents beside it link to each section on GitHub.

You set up the repo for atomic-claude conventions. Detect first, propose second, apply only what the user confirms.

Pre-flight and scope detection

A wiki/ outside a git repo is a realm root, a git repo without one is repo scope, and a git repo holding a wiki/ is the user's call, defaulting to repo.

flowchart TD
    G{"Inside a git repo?"} -->|no| W{"wiki/ present?"}
    W -->|yes| RL["Scope: realm"]
    W -->|no| I{"User inits git?"}
    I -->|no| X["Refuse"]
    I -->|yes| N["git init"]
    N --> RP["Scope: repo"]
    G -->|yes| W2{"wiki/ present?"}
    W2 -->|no| RP
    W2 -->|yes| Q{"User picks?"}
    Q -->|realm| RL
    Q -->|repo or cancel| RP
  • Inside a git repo?: run in parallel with the wiki/ check: git rev-parse --is-inside-work-tree 2>/dev/null and test -d wiki && echo wiki-present || echo wiki-absent.

  • User inits git?: ask the user:

    Not a git repo. Initialize one?
    - Yes, run git init
    - No, stop
    
  • User picks?: ask the user in one batched question block; accept realm or repo as typed input or a button choice:

    A wiki/ directory exists inside this git repo. Which scope applies?
    - realm — this directory is a realm root (wiki/ is the attached wiki repo)
    - repo  — this is a single git repo with its own wiki/ storage
    - unsure / cancel — treat as repo
    

    On cancel, an ambiguous answer, or "unsure / cancel", note "wiki-type defaulted to repo (wiki/ present inside git repo — user did not confirm realm)" in the Step 5 output.

  • Scope: realm / Scope: repo: sets WIKI_SCOPE. It is surfaced in the Step 5 report only — the wiki pipeline (/refresh-wiki) writes the <wiki-type> marker itself, into the wiki index it generates.

Step 1 — Audit

Inspect the repo. Build this status table:

Convention Present? Status
.gitignore exists check test -f .gitignore exists / missing
.gitignore has tmp/ grep ^tmp/?$ yes / no
Scratchpad ignored read state_root from atomic where --json as <state-root> (.atomic by default), then git check-ignore -q <state-root>/.scratchpad/probe (atomic repo init writes the rule to <state-root>/.gitignore). n/a when <state-root> is outside the repository yes / no / n/a
Worktrees location ignored read worktrees from atomic where --json as <worktrees>, then git check-ignore -q <worktrees>/probe (the rule may live in a nested .gitignore). n/a when <worktrees> is empty (off) or absolute (outside the repository). Placement per harness: the atomic-git-discipline reference references/worktrees.md yes / no / n/a
Project steering file at repo root test -f AGENTS.md -o -f CLAUDE.md -o -f claude.md exists / missing
docs/ directory test -d docs exists / missing
docs/spec/ directory test -d docs/spec exists / missing
docs/design/ directory test -d docs/design exists / missing
README.md at repo root test -f README.md exists / missing
SessionStart hook registered in .claude/settings.json parse .claude/settings.json (JWCC tolerated) and look for a SessionStart entry whose hooks[].command value is atomic hooks session-start (the inline command written by atomic hooks install) registered / missing
docs/wiki/index.md test -f docs/wiki/index.md exists / missing
Signals @-ref wired present in the project steering files — claude.local.md, CLAUDE.local.md, the shared AGENTS.md, or the loader beside it, CLAUDE.md or claude.md — check each with grep -qF '@docs/wiki/index.md' <file> (mirrors the atomic-wiki-inferrer search order). A ref found only in AGENTS.md counts when no loader sits beside it or the loader carries @AGENTS.md; otherwise report no. n/a only when none of those files exist. Only docs/wiki/index.md (the compact router) is @-ref'd — docs/wiki/scan.md is too large for context on big repos and is read by the inferrer on demand. yes / no / n/a
Legacy .signalsignore at repo root test -f .signalsignore present (needs migrating) / absent
Wiki steering file test -f docs/wiki/AGENTS.md -o -f docs/wiki/CLAUDE.md exists / missing

Read the full file on GitHub · 378 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 12d ago Changed · +18 lines scan D → A 1aa1ff5af607
  2. 3mo ago First seen · 360 lines · 43 tokens per session scan D 00437a19bcfe

Subscribe to this mod's changes

setup-wiki is a command published in the GitHub repository damusix/atomic-claude (117 stars, last pushed yesterday), licensed MIT. It adds 43 tokens to every session and 4,711 once invoked, about $0.0002 per session on Opus 5.5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.

Related

setup-wiki compared with commands from other repositories

setup-wiki next to 6 commands from other repositories
ModTypeStarsLast pushLicenceScanTokensWorks with
setup-wikidamusix/atomic-claudeCommand117yesterdayMITA43Claude Code
agentloop-audit-dashboardalibaba/loongsuite-pilotCommand271todayApache-2.0A21Claude Code
agentloop-audit-queryalibaba/loongsuite-pilotCommand271todayApache-2.0A20Claude Code
add-agentivan-magda/claude-code-plugin-templateCommand725mo agoMITA12Claude Code
add-commandivan-magda/claude-code-plugin-templateCommand725mo agoMITA9Claude Code
add-skillivan-magda/claude-code-plugin-templateCommand725mo agoMITA11Claude Code
initivan-magda/claude-code-plugin-templateCommand725mo agoMITA13Claude Code