archive

A procedure for filing away a change folder after its branch has already been merged into the main codebase.

In plain words
What is it for?
It helps verify the merge using Git, check the change status, and move shipped changes into an archive with their ship date.
Why use it?
It prevents unfinished or unmerged work from being marked complete and keeps completed changes out of the active work area.

Skill for Claude CodeCodex

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 skills/ribeirogab/specwright/archive
Any agent
npx skills add ribeirogab/specwright --skill archive
Clone the repo
git clone --depth 1 https://github.com/ribeirogab/specwright

Made for: Claude Code, Codex.

Per session 65 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 770 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.00065 $0.00770
Opus 5 $0.00032 $0.00385
Sonnet 5 $0.00013 $0.00154
Haiku 4.5 $0.00006 $0.00077

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

Security

Grade A, and why

archive 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.

plugins/sw/skills/archive/SKILL.md · 81 lines

How it starts

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

archive — close out a merged change

The one step that happens after the maintainer merges. Every other command stops before that point: sw:review ends at lgtm and sw:ship ends with it, because merging is never the agent's call. This skill picks up on the other side and retires the change folder from the working set.

It does not merge, does not push, and does not review. It confirms and files.

Announce at start: "Archiving the change."

Inputs

$ARGUMENTS names a change folder or slug → use it. Empty → list the changes in .specwright/changes/*/ whose ticket says status: shipped and ask which; a single candidate may be used directly.

A change that is not shipped is not archivable. Say which status it carries and stop — pending or in-progress means the work is unfinished, and blocked means it needs a decision, not a filing cabinet.

Confirm the merge from git alone

The change's branch is in its task file's branch: frontmatter. Resolve the default branch, then ask git whether that branch's tip is already an ancestor of it:

git fetch --quiet origin
default="$(git symbolic-ref --quiet --short refs/remotes/origin/HEAD | sed 's|^origin/||')"
default="${default:-main}"
git merge-base --is-ancestor "<branch>" "origin/$default"

Exit 0 means every commit on that branch is contained in the default branch: it merged, whatever the remote host is and whoever pressed the button. A non-zero exit means it did not — stop, report that the branch is not in origin/<default> yet, and archive nothing.

This check is deliberately host-agnostic. It works on GitHub, GitLab, Gitea, a bare remote on a colleague's machine, or a squash merge that rewrote the commits, because it asks git about containment rather than asking a forge about a pull request.

When the branch no longer exists locally, resolve it from origin/<branch>; when neither exists, the branch was deleted after merging — say so and ask the maintainer to confirm the merge before continuing.

Read the full file on GitHub · 81 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 · 81 lines · 65 tokens per session scan A 7acb09260068

Subscribe to this mod's changes

archive is a skill published in the GitHub repository ribeirogab/specwright (3 stars, last pushed 24d ago), licensed MIT. It adds 65 tokens to every session and 770 once invoked, about $0.0003 per session on Opus 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-31.

Related

Other skills, from other repositories

review-depth

Decide how much review a change has earned, before reviewing it. Selects quick, standard, or deep from stated signals (reviewable changed lines, directory spread, trust-boundary risk flags, blast radius, documentation-only scope), reports the signal table and the rule that fired, then runs house-review at the selected…

hams-ollo/zen-agent-skills · 180 tokens

doc-sync

Use when code has moved and the documentation may not have, or when a documentation set needs auditing for stale claims. Detects documentation drift by checking prose claims against repository facts, classifies every document as current-state (correctable), contract (report-only, human-owned) or ledger (skipped), and…

hams-ollo/zen-agent-skills · 193 tokens

init-worktracking

Scaffold a portable, agent-optimized spec-driven work-tracking system into the current repository: AGENTS.md (global rules + agent reading protocol), a .tasks/ directory of atomic task files, and (by tier) ROADMAP.md, CHANGELOG.md, a validate.py checker, and thin CLAUDE.md/Cursor/Copilot pointers. Choose a footprint…

hams-ollo/zen-agent-skills · 207 tokens

reconcile-worktrees

Safely consolidate one or more isolated git worktrees (for example left behind by parallel background agents, or from the fix-batch skill) into the main working tree, without committing or merging blindly. Use whenever asked to "reconcile the worktrees", "merge these agent branches", "bring the worktree changes back…

hams-ollo/zen-agent-skills · 161 tokens

verifier-agent

Use before reconciling or landing an implementation to independently verify it against its approved spec and its task's acceptance criteria. Runs the declared verification commands and records each exact outcome, composes the spec-conformance lens so a contract divergence fails the run even when every command passes…

hams-ollo/zen-agent-skills · 166 tokens

spec-author

Use when turning a raw idea, feature request, or bug into a persistent behavioral spec before any tasks or code. Drafts a scenario-based spec (problem, goals, non-goals, constraints, Given/When/Then scenarios with stable S-NNN ids, proposed surface, open questions), composes the spec-quality lens to self-check and…

hams-ollo/zen-agent-skills · 133 tokens