sync-plan

A command that previews which files a Crabbox run would upload and shows where the largest files are.

In plain words
What is it for?
It reads the local Git checkout, ignore rules, configuration exclusions, and built-in artifact exclusions, then prints a summary or JSON output.
Why use it?
It lets you check the local sync set before starting a paid or remote synchronization and helps confirm that ignored build artifacts are excluded.

Command

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.

agentmods
npx agentmods add commands/openclaw/crabbox/sync-plan
Clone the repo
git clone --depth 1 https://github.com/openclaw/crabbox
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,270 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. Scan, not verified.
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 $0.00000 $0.01270
Opus 5 $0.00000 $0.00635
Sonnet 5 $0.00000 $0.00254
Haiku 4.5 $0.00000 $0.00127

Measured 2d ago against content hash 11907bc41dec, method: parsed. Prices are Anthropic first-party input rates as of 2026-08-30, from the pricing page.

Security

Grade A, and why

sync-plan 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 2d 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.

docs/commands/sync-plan.md · 132 lines

How it starts

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

sync-plan

crabbox sync-plan prints the local sync manifest and its size hotspots without leasing a box. Use it to preview what crabbox run would upload before paying for a cold sync, or to confirm that artifacts dropped out of the manifest after editing .crabboxignore.

crabbox sync-plan
crabbox sync-plan --limit 10
crabbox sync-plan --json

The command reads only your local Git checkout. It does not require a lease, does not call the broker, and does not call any provider API.

What it reads

sync-plan builds the same manifest crabbox run uses, so the file set matches what an actual sync would ship:

  • files reported by git ls-files --cached --others --exclude-standard (tracked files plus non-ignored untracked files);
  • root .crabboxignore patterns;
  • sync.exclude patterns from config;
  • Crabbox's built-in cache/build excludes.

Ordered exclude rules are applied before size accounting; a later !pattern can re-include a path matched by an earlier rule.

Crabbox-owned built-ins for ambiguous artifact directory names (dist, dist-runtime, coverage, playwright-report, test-results, .build, and target) omit untracked output but do not silently remove Git-tracked regular files. Text output adds one bounded warning naming protected paths and matching patterns. Explicit sync.exclude and .crabboxignore rules remain authoritative for tracked files, including bare component-wide patterns.

The same preflight rejects tracked non-gitlink paths hidden by sparse-checkout or skip-worktree state only when they remain in the effective manifest after sync.include and ordered excludes. On Git older than 2.41, an ambiguous missing in-scope path fails closed; out-of-scope paths do not affect the plan.

Output

The first line reports the candidate file count and total size. If the checkout has tracked files that were deleted locally (and would be pruned on the remote), a deleted tracked paths line follows. Then sync-plan prints the largest files and the largest top-level or second-level directories.

Read the full file on GitHub · 132 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. 2d ago First seen · 132 lines · 0 tokens per session scan A 11907bc41dec

Subscribe to this mod's changes

sync-plan is a command published in the GitHub repository openclaw/crabbox (1,343 stars, last pushed 2d ago), licensed MIT. It costs nothing until one of its globs matches a file; then it loads 1,270 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.