agentleFS
aykyusufaykyusuf/crew-chief/skills/crew-handoff/SKILL.md

crew-handoff

Skill8 starsChanged 11 days agoMITView on GitHub

Sets up session handoff files (STATUS.md, tasks.json, PROGRESS.md and a start/end routine in CLAUDE.md) so a new Claude Code session picks up where the last one stopped. Use when the user accepts crew-chief's handoff offer, or asks to set up handoff, progress, or status files for this project. Never overwrites existing files.

The file

We split this skill into the rules it gives an agent

3 rules. About 0 are common, 0 are distinctive, and 3 are very specific to this project.

  • ≈0

    Common · estimate

    Many files like this have a rule of this kind.

  • ≈0

    Distinctive · estimate

    This author's own choices. Worth a look.

  • 3

    Very specific

    Tied to their project's names, files or tools. Probably skip.

  • Common
  • Distinctive
  • Very specific
  1. Very specific:

    Run git -C <cwd> rev-parse --show-toplevel (cwd: the argument if given, otherwise the session's directory).

    line 13
  2. Very specific:

    If the user declines, record never or later as in step 4 and stop.

    line 40
  3. Very specific:

    Create files only where none exists.

    line 50

≈ “Common” is an estimate: at least 1 in 5 of the 408,460 skill files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.

Keep what fits and drop the rest. Your version, ready for your agents.
Files
SKILL.md

Set up session handoff files. Arguments: $ARGUMENTS (optional sub-project directory; default: the repository root). Templates are in ${CLAUDE_SKILL_DIR}/assets/.

Why: a fresh session otherwise rediscovers the project from scratch. This is the pattern in Anthropic's "Effective harnesses for long-running agents" (https://www.anthropic.com/engineering/effective-harnesses-for-long-running-agents): a progress file, a JSON task list where only the status changes (models alter JSON less readily than Markdown), and reading git log plus the progress file at the start of each session.

0. Is there a git repository?

Run git -C <cwd> rev-parse --show-toplevel (cwd: the argument if given, otherwise the session's directory). If it finds a repository, go to step 1.

No repository:

  • If the prompt that started this already says what the user chose (git init first, or set up without git), follow it. For git init: run git init in that directory and use the new repository root as the target. For without git: the target is that directory itself.
  • Otherwise ask once (AskUserQuestion), in the user's language: "git init, then set up" (recommended) or "Set up without git in this folder". Nothing is written before the answer. If they decline both, record later (step 4) and stop.

1. Look before writing

Target directory: the argument if given; otherwise the repository root (git rev-parse --show-toplevel); with no repository, the current directory.

Search the target and one level below for handoff-like files under any name or language, for example STATUS.md, PROGRESS.md, HANDOFF.md, tasks.json, feature_list.json, claude-progress.txt, durum.md, ilerleme.md, and for a session start/end routine in CLAUDE.md (a crew-chief:handoff block, or headings such as "Session start" or their translation).

  • Something equivalent exists: do not create a parallel set. Show what you found and ask whether to keep using it (default), add only the missing pieces next to it, or stop. Never rename or rewrite the user's files. If they keep using it, record installed (step 4) so the offer does not return. If their STATUS.md has no Constraints section (a heading named Constraints or Kısıtlar), say what it is for (the compact flow puts those lines back verbatim after every compaction) and ask whether to add the empty section; add it only after a yes.
  • Nothing exists: continue.

2. Show the plan and a preview, then write

Show the user, in their language:

  • the exact files to be created (only missing ones) and the block to add to CLAUDE.md between <!-- crew-chief:handoff:start and <!-- crew-chief:handoff:end -->; the rest of CLAUDE.md stays as it is;
  • that nothing is committed and no other file changes;
  • a short preview of each file's contents, filled from what you can verify in the repository (README, build files, scripts, CI config, git log). Mark anything you could not verify as "unverified"; never invent commands, results, or tasks.

Whether to wait depends on what the user already said:

  • The user already said yes (they accepted crew-chief's offer, the prompt says so, or they asked you to set it up, for example "kur" or "set up handoff"): do not ask again. Show the plan and preview and go straight on to step 3 in the same turn.
  • Step 1 found equivalent files (the case where you asked what to do with them): wait for their answer before writing anything.
  • Anything else (the skill was invoked without a clear yes): wait for confirmation.

If the user declines, record never or later as in step 4 and stop.

3. Write

Using ${CLAUDE_SKILL_DIR}/assets/ as templates:

  • STATUS.md: now, constraints (rules the user gave, verbatim, with their reason and scope when given; start empty, never invent one), environment (start, stop, build, test commands you actually found), next, open questions, failed attempts, decisions.
  • tasks.json: keep the _rule text as is. Add tasks only from what the user said or the repository states (open TODOs, README roadmap); otherwise leave one example task for the user to replace. Every task needs a measurable done_when.
  • PROGRESS.md: one dated line saying the files were set up.
  • CLAUDE.md: append ${CLAUDE_SKILL_DIR}/assets/claude-md-routine.md if no crew-chief:handoff block exists (create CLAUDE.md if missing). If the block exists, leave it alone.

Create files only where none exists. Check that tasks.json parses as JSON.

4. Record the answer

So the session hook does not offer again, append one line to ${CLAUDE_PLUGIN_DATA}/handoff-offers.tsv (create the directory if needed), tab-separated: the repository root, the answer (installed, never, or later), and the current Unix time from $(date +%s) (digits only), for example printf '%s\tlater\t%s\n' "$root" "$(date +%s)" >> "${CLAUDE_PLUGIN_DATA}/handoff-offers.tsv". Skip this step when the path above still reads literally ${CLAUDE_PLUGIN_DATA} (skills installed without the plugin: there is no offer to silence).

5. Report

List what was created, what was left untouched, and anything marked unverified. Do not commit.

Download now (ZIP)

Does it work?

Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.

No reviews yet

People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.

  • It worked
  • Partly
  • It didn't
What did you use it for? e.g. Reviewing pull requests in a Rails app

Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.

Your trail

Files you open will collect here, so you can find them again.

Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.

Now do this for your own.

Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.