forge: Command for Claude Code

.claude/commands/sync-docs.md

sync-docs is a command for Claude Code from initializ/forge. It costs 0 tokens per session (1,533 once invoked), scanned A, original, Apache-2.0.

A documentation-update command for a software repository. It maps changed Go code paths to the documentation pages that may need corresponding updates.

In plain words
What is it for?
Use it after feature work to inspect changed files and update the related documentation for authentication, runtime, security, tools, memory, scheduling, secrets, channels, and validation.
Why use it?
It reduces the chance that feature changes leave the documentation inaccurate or incomplete. The path mapping helps identify which pages are affected by a code change.

Command for Claude Code

Written for Claude Code: installed under .claude/. Also seen: reads .claude/ paths.

This is initializ/forge's own configuration. It tells Claude Code how to work on forge itself, so it is not a mod to install elsewhere. Copy it as a starting point and replace the rules that are about this project. Everything forge configures →

Reuse

Borrowing it

Nothing to install: this file belongs to initializ/forge. Take a copy, put it at the same path in your own repository, and replace the rules that are about this project with yours.

Copy the file
curl -O https://raw.githubusercontent.com/initializ/forge/main/.claude/commands/sync-docs.md
Clone the repo
git clone --depth 1 https://github.com/initializ/forge

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 sync-docs

README.md
[![agentmods](https://agentmods.dev/badge/commands/initializ/forge/sync-docs/github.svg)](https://agentmods.dev/commands/initializ/forge/sync-docs)
Your own site
<a href="https://agentmods.dev/commands/initializ/forge/sync-docs"><img src="https://agentmods.dev/badge/commands/initializ/forge/sync-docs/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 sync-docs

Your own site · 80×15
<a href="https://agentmods.dev/commands/initializ/forge/sync-docs"><img src="https://agentmods.dev/badge/commands/initializ/forge/sync-docs.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 0 Only the description is in the session, so the agent can decide to use it. The body loads when it is invoked.
When invoked 1,533 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.00000 $0.01533
Opus 5.5 $0.00000 $0.00613
Sonnet 5.5 $0.00000 $0.00307
Haiku 4.5 $0.00000 $0.00153

Measured 2mo ago against content hash ac89e86ea598, method: parsed. Prices are Anthropic first-party input rates as of 2026-10-07, from the pricing page.

Security

Grade A, and why

sync-docs 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 2mo 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.

.claude/commands/sync-docs.md · 75 lines

How it starts

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

Sync Documentation

After feature work, update the affected documentation to reflect code changes.

Steps

  1. Identify changed files — Run git diff main --name-only to find modified Go files.

  2. Map files to docs — Use this mapping to determine which docs need updates. Paths match the actual docs/ tree (nested under core-concepts/, reference/, security/, deployment/, skills/).

    Changed path pattern Affected docs
    forge-core/auth/ docs/security/authentication.md, docs/security/audit-logging.md
    forge-core/runtime/ docs/core-concepts/runtime-engine.md, docs/core-concepts/hooks.md
    forge-core/security/ docs/security/overview.md, docs/security/egress-control.md
    forge-core/tools/ docs/core-concepts/tools-and-builtins.md
    forge-core/llm/ docs/core-concepts/runtime-engine.md
    forge-core/memory/ docs/core-concepts/memory-system.md
    forge-core/scheduler/ docs/core-concepts/scheduling.md
    forge-core/secrets/ docs/security/secret-management.md
    forge-core/channels/ docs/core-concepts/channels.md
    forge-core/validate/ docs/reference/forge-yaml-schema.md
    forge-cli/cmd/ docs/reference/cli-reference.md
    forge-cli/runtime/ docs/core-concepts/runtime-engine.md
    forge-cli/server/ docs/core-concepts/how-forge-works.md
    forge-cli/runtime/admission_engine.go, forge-cli/runtime/admission_loader.go, forge-cli/server/admission_middleware.go, forge-core/runtime/admission.go docs/security/admission.md (full operator + platform-integrator reference), docs/security/audit-logging.md (task_admission_denied event row), docs/core-concepts/observability-tracing.md (admission.check span attribute table) — keep wire shape, env var names, fail-open semantic, and HTTP 402 response body all in sync
    forge-cli/channels/ docs/core-concepts/channels.md
    forge-cli/tools/ docs/core-concepts/tools-and-builtins.md
    forge-cli/internal/tui/ docs/reference/cli-reference.md (wizard flow)
    forge-plugins/ docs/core-concepts/channels.md, docs/reference/framework-plugins.md
    forge-ui/ docs/reference/web-dashboard.md
    forge-ui/handlers_skill_builder.go, forge-ui/skill_builder_context.go, forge-ui/skill_validator.go, forge-ui/static/app.js (SkillBuilderPage), forge-cli/cmd/ui_skill_save.go docs/reference/web-dashboard.md (§ Skill Builder + § Editing an Attached Skill), docs/skills/writing-custom-skills.md (§ Iterating from the Skill Builder UI) — keep edit-mode endpoints, prompt-trailer behavior, and overwrite-clears-scripts rule in sync
    forge-skills/ docs/skills/writing-custom-skills.md, docs/skills/contributing-a-skill.md
    forge-skills/registry/image-registry.yaml, forge-core/packaging/ docs/core-concepts/binary-dependencies.md — refresh the registry contents, install methods, or Dockerfile shape sections; keep the source-file list at the bottom in sync with the actual files touched
    forge-cli/templates/Dockerfile.tmpl, forge-cli/build/dockerfile_stage.go docs/core-concepts/binary-dependencies.md (image-shape section), docs/deployment/docker.md
    forge-core/types/ / forge.yaml docs/reference/forge-yaml-schema.md
    CHANGELOG.md (rendered into release notes; no per-doc sync needed)
    Any of forge-core/**, forge-cli/**, forge-ui/**, forge-plugins/**, forge-skills/**, docs/**, CHANGELOG.md, forge.yaml schema .claude/skills/forge.md — refresh the affected section(s) of the comprehensive knowledge skill. Sweep the specific section that maps to the changed area; don't rewrite the whole file. Keep the table-of-contents anchors in sync with the section headings.
    forge-ui/skill_builder_context.go (specifically the skillBuilderSystemPrompt constant) .claude/skills/forge-skill-builder.md — re-port verbatim. The body must remain byte-identical to the Go constant apart from un-doing the Go string-concatenation escapes (` + "```" + ` → triple-backticks, etc.). Do not edit either side without updating the other.

Read the full file on GitHub · 75 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. 2mo ago First seen · 75 lines · 0 tokens per session scan A ac89e86ea598

Subscribe to this mod's changes

sync-docs is a command published in the GitHub repository initializ/forge (235 stars, last pushed yesterday), licensed Apache-2.0. It costs nothing until one of its globs matches a file; then it loads 1,533 tokens. 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

sync-docs compared with commands from other repositories

sync-docs next to 6 commands from other repositories
ModTypeStarsLast pushLicenceScanTokensWorks with
sync-docsinitializ/forgeCommand235yesterdayApache-2.0A0Claude Code
04-content-briefViryaZheng/recomby-geoCommand4544mo agoMITA96Claude Code
01-intakeViryaZheng/recomby-geoCommand4544mo agoMITA0Claude Code
02-auditViryaZheng/recomby-geoCommand4544mo agoMITA94Claude Code
03-gapViryaZheng/recomby-geoCommand4544mo agoMITA58Claude Code
05-productionViryaZheng/recomby-geoCommand4544mo agoMITA74Claude Code
06-distributionViryaZheng/recomby-geoCommand4544mo agoMITA63Claude Code