end

A command that records the current coding session in Bonfire's .bonfire/index.md file. It updates the sections for work in progress and completed session history.

In plain words
What is it for?
Use it at the end of a session in a repository that has opted into Bonfire, including when the index file needs to be created or updated.
Why use it?
It leaves the next session with a concise record of the goal, progress, blocked work, next steps, or changed files.

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/vieko/bonfire/end
Clone the repo
git clone --depth 1 https://github.com/vieko/bonfire
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,125 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.01125
Opus 5 $0.00000 $0.00562
Sonnet 5 $0.00000 $0.00225
Haiku 4.5 $0.00000 $0.00112

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

Security

Grade A, and why

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

skills/bonfire/commands/end.md · 66 lines

How it starts

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

End Session (fallback)

Outcome

<git-root>/.bonfire/index.md reflects the current session's work inside its two managed fence blocks — no native adapter required.

Acceptance Criteria

  1. Opt-in respected: <git-root>/.bonfire/ exists. If not, exit silently without creating anything.
  2. Per-repo opt-out respected: if <git-root>/.bonfire/config.json exists and has { "auto": false }, exit silently.
  3. File bootstrapped if missing: if <git-root>/.bonfire/index.md doesn't exist, create it from templates/index.md (which includes both fence markers).
  4. In-flight fence updated between <!-- bonfire:auto-inflight:start v1 --> and <!-- bonfire:auto-inflight:end -->:
    • First line inside the fence: _Updated YYYY-MM-DD from <host>:<short-session-id> on \`_`
    • Then ## In flight heading
    • Then ### Goal with a one-line session headline
    • If you have structured context (e.g., "what's done", "what's blocked"), add ### In Progress, ### Blocked, ### Next Steps subsections
    • Otherwise add ### Modified files with output of git diff --name-only HEAD (up to 10 entries)
  5. Sessions fence updated between <!-- bonfire:auto-sessions:start v1 --> and <!-- bonfire:auto-sessions:end -->:
    • One row per session, format: - YYYY-MM-DD [<host>:<short-session-id>] <branch> — <one-line headline>
    • Insert the new row at the top (newest first)
    • De-dupe by [<host>:<short-session-id>] — same session updates its existing row instead of duplicating
    • Cap at 5 newest rows; drop the rest
  6. Atomic write: write to a tmpfile and rename. Don't truncate-in-place.

Constraints

  • Never modify content outside the fence markers. Everything outside is user-curated.
  • Never inject fence markers into a file that doesn't have them. If index.md exists but lacks fences, exit without writing — user has chosen a different layout.
  • Short session id: use ≥8 random hex chars from the session's UUID (skip the first 8 chars if it's UUIDv7, since those encode the timestamp and collide for time-clustered sessions). If your agent has no native session id, derive a stable one from a conversation hash and document its scope.
  • Host token: use a short identifier for your agent (pi, claude, codex, opencode, etc.) so multi-agent users can tell rows apart.
  • Garbage detection: if the existing in-flight or sessions row matches /no conversation (content|messages?)/i, treat it as missing (upstream bug pattern) and overwrite with current session data.
  • Stale detection: if the in-flight's _Updated from <host>:<id>_ line references a different session id than yours, overwrite with current session data. The in-flight should always reflect the most recent session.

Read the full file on GitHub · 66 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 · 66 lines · 0 tokens per session scan A 382692d72adb

Subscribe to this mod's changes

end is a command published in the GitHub repository vieko/bonfire (10 stars, last pushed 8d ago), licensed MIT. It costs nothing until one of its globs matches a file; then it loads 1,125 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-31.