Skip to content
Projects

Claude Kit

Live usable

The Claude Code setup I built this portfolio with: rules, agents, hooks and a status line that does not lie, the same on every machine.

My Claude Code setup, published and sanitised: lane-based routing rules, six subagents, ten skills, five hooks and a status line that tells the truth about context, cache and the HANDOFF. Mirror scripts keep it identical on every machine without deleting anything.

Technology

  • AI & agents
  • Automation

Sector

  • Dev tools

Problem

I used Claude Code all day on three fronts and the same problems showed up in all of them: the most expensive model doing a small model's job, sessions losing the thread, and finding out too late that context was huge, the cache was cold or the handoff was stale.

Approach

One repo is the source of truth for what Claude Code reads on every machine: CLAUDE.md, rules, agents, skills, hooks, the status line and rules/thresholds.json, the only place with numbers. sync-to-home.sh copies it into ~/.claude with a backup, merges only the portable settings.json keys and never deletes; verify.sh checks it landed and runs the three suites.

The bar reads the JSON Claude Code hands it on every turn and draws two lines: context in absolute tokens, the cache state in one word (caliente, enfriando, fría) plus its minutes, plan quota, git and how fresh the HANDOFF is. A missing field is painted ⚠, never 0. Lesson 01 of the Code like me route walks through it sector by sector. The status line simulator (the demo link) shows it reacting to controls: every state is the script’s real output, pre-rendered.

For anyone with more than one machine, the optional enjambre module (--with enjambre) adds a hook that blocks a raw ssh to the nodes and makes every delegation go through enjambre’s queue.

Limits: the bar takes about 476 ms on Windows, over the 200 ms target; the kit’s CLAUDE.md is its author’s own rules and is meant to be edited. Code under Apache-2.0.

Result

automated tests passing
140
statusline 67 + hooks 38 + enjambre module 23 + /route 12, Windows, 2026-10-15
full status-line render on Windows + Git Bash
476ms
docs/statusline-internals.md, 2026-09-22
session lifecycle hooks
5
home/.claude/hooks, 2026-10-15
skills
10
home/.claude/skills, 2026-10-15
subagents by lane
6
home/.claude/agents, 2026-10-15

What I'd do next

  • Cut the bar's render time or accept the budget: 476 ms measured against a 200 ms target; the Mac is not measured yet.
  • Port the ideas to Codex CLI and Gemini CLI.
  • An UNATTENDED: line so a session can accept an approved scope without stopping to ask.

Architecture

Claude Code configuration kit: rules, agents, hooks and a status line mirrored to every machine without deleting anything.

  • PC Windows
  • Mac mini
  • GitHub
publica filtradogit pull --ff-onlylista del espejosync-to-homesync-from-homecompara derivacorre suitescarga al arrancarJSON por stdinpayload por stdinlee umbraleslogs y borradoressnapshot de sesión--drifthooks, HOME falsoumbrales de derivatexto de la barraejecuta verify.shrepo fuente · fuera de este repoFuente privada y filtrotools/build-kit.sh (el script noestá en este repo)externo · gitGitHubrepo público, rama mainrepo · clon localRepo Claude Kithome/.claude · templates · docs ·testsscripts · bashScripts de espejosync-to-home.sh · sync-from-home.sh· mirror-lib.sh · kit-update.shscript · bashverify.shcomprobaciones con eval · jq · gitpruebas · bashPruebasdirectorio de usuario · cada máquinaConfiguración instalada~/.claudeexterno · sesión de trabajoSesión de Claude Codeproceso de Claude Codehooks · bash + jqCinco hookslog-event · session-drift-warn ·precompact-draft · compact-reinject· log-tool-failuredatos · JSONUmbralesrules/thresholds.jsonscript · bash >= 4.2Barra de estadostatusline.sh · jq · gitarchivos localesRegistros y estadoevents.jsonl · tool-failures.jsonl ·snapshots · docs/handoffsC4 · nivel 2 (contenedores) · tráfico ambiente = llamadas reales · clic en una caja para el detallelínea continua = HTTP/SQL · punteada = adaptador elegido por configuración · caja punteada = existe fuera del proyecto
open in a new tab ↗

Flows you can replay

  1. Instalar o actualizar el kit
  2. Una sesión lee las reglas y un hook actúa
  3. La barra de estado se repinta
  4. Módulo enjambre: la guardia de ssh
  5. Publicar la versión pública filtrada

How it was made

  • 01 — Read your bar: what Claude Code is telling you on every turn — Look at the two lines of the status bar and know, at a glance, four things: how much context you have left before the session degrades, whether the cache is still warm, whether your work is safe (commit, push, HANDOFF)…
  • Hooks — Five scripts under home/.claude/hooks/, wired in home/.claude/settings.json. Every hook always exits 0 — a hook must never be the reason a session, a compaction, or the tool it watches fails.
Part of the Claude Code Ecosystem →

Sibling projects

Learn how it was made → Code Like Me