bridge-attach
Skill16 starsChanged 31 days agoMITView on GitHub
Attaches this Bridge to a Claude Code session that works in another repo: /bridge-attach runs Phase 0 against the Bridge root and puts a short attach text (manual, log, inbox, state of the repo) into the session, at start or later; nothing is written into the repo. Shortcut at start, also for Codex and Copilot CLI: bin/bridge-attach. Trigger: "/bridge-attach", "attach the bridge", "bridge in this repo", "start claude with the bridge", "bridge-attach".
In this repository47 other files it gives its agents.
- AGENTS.mdAGENTS.md
- skills/board-pilot/references/agents.mdAGENTS.md
- .github/copilot-instructions.mdCopilot instructions
- a2aSkill
- archiveSkill
- board-pilotSkill
- bridge-auditSkill
- bridge-contributeSkill
- bridge-curatorSkill
- bridge-explorerSkill
- bridge-greetingSkill
- bridge-leak-checkSkill
- bridge-learnSkill
- bridge-onboardSkill
- bridge-overlaySkill
- bridge-promoteSkill
- bridge-statusSkill
- bridge-syncSkill
- briefingSkill
- browserSkill
- calendarSkill
- capability-brokerSkill
- channelSkill
- cmuxSkill
- cockpitSkill
- dashboardSkill
- debriefSkill
- doc-systemSkill
- github-projects-managerSkill
- html-canvasSkill
- html-slidesSkill
- inbox-notifySkill
- knowledge-repo-initSkill
- mail-draftSkill
- mandantsSkill
- meeting-transcriptionSkill
- object-storeSkill
- onboard-simSkill
- remoteSkill
- scheduleSkill
- secretsSkill
- spec-kickoffSkill
- task-close-postmortemSkill
- tmuxSkill
- tracker-syncSkill
- workloadSkill
- workspaceSkill
The file
We split this skill into the rules it gives an agent
3 rules. About 0 are common, 2 are distinctive, and 1 is very specific to this project.
≈0
Common · estimate
Many files like this have a rule of this kind.
≈2
Distinctive · estimate
This author's own choices. Worth a look.
1
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Very specific: line 23
If BRIDGE_ATTACH is 1 in the environment, the session was started with the shortcut below and is attached already.
- Distinctive: line 48
Write into the repo the session works in.
- Distinctive: line 49
Run Phase 0 or onboarding in that repo.
≈ “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.
Files
bridge-attach
A Bridge session starts in the Bridge folder; the work happens in repos. This skill gives a
session in any repo exactly one Bridge, the one this skill lives in, at start or in the middle
of the work. Background, measurements and limits: docs/bridge-attach.md.
Paths.
$SKILL_DIRis this skill's folder (the Base directory). Run Bridge commands as"$SKILL_DIR/../../bin/bridge-run" <command>, written as a path from the session's own folder: the path resolves through the.claude/skillslink to the Bridge'sbin/, andbridge-runexecutes the command in the Bridge root. Nocdis needed; acdinto the Bridge moves this session's shell out of its repo, and spelled out by hand$SKILL_DIR/../..can end in.claude/. The attach text names the root.
When the skill runs
- If
BRIDGE_ATTACHis1in the environment, the session was started with the shortcut below and is attached already. Run step 2 only when the user asks for a fresh state. - Run
"$SKILL_DIR/../../bin/bridge-run" python3 scripts/bridge-attach.py slice --cwd "$PWD"and take its output as this session's attach text. It names the Bridge, the context tag of this repo, the manual, how Bridge commands and log rows are written, the memory folder, and the state of the repo's context: matching inbox items (all others only counted), board counts, recent log rows. Exit 3 means the Bridge is not attachable (not on auser/*branch, nobridge-config.yaml, or the folder is the Bridge itself): say why and stop. - Say in one line what this way does not attach: the Bridge's project hooks (log check, time tracking) and its memory as auto memory. The shortcut at start brings both.
Three ways in
| Way | How | What comes along |
| 1 · in the session, any time | /bridge-attach. The skill must be listed: the session was started with --add-dir <root>, or the user types /add-dir <root> first | attach text as conversation content; /compact re-attaches this skill's own text, not the attach text, which is summarized with the rest of the conversation |
| 2 · at start | claude --add-dir <root> "/bridge-attach", or the shortcut <root>/bin/bridge-attach claude | the shortcut puts the attach text into the system prompt (no size cap, survives compaction), replays the Bridge's own hooks and sets its memory; also codex (with the Bridge skills as bridge:<name>) and copilot |
| 3 · automatic | not built: a SessionStart hook cuts its text at 10,000 characters and a hook in the user's global settings fires in every headless run on the machine | a terminal app that starts agents can call bridge-attach.py plan instead |
The shortcut refuses (exit 3) on the same conditions as step 2 and prints one line per limit
that applies, for example "no Bridge memory inside a cmux-style terminal".
<root>/bin/bridge-attach plan claude prints what it would run and starts nothing.
What it never does
- Write into the repo the session works in.
- Run Phase 0 or onboarding in that repo.
- Attach a second Bridge, or read another instance's files.
- Install a hook in the user's global settings.
Check it
"$SKILL_DIR/../../bin/bridge-run" python3 scripts/bridge-attach.py check # NORMAL user/<name>, exit 0
"$SKILL_DIR/../../bin/bridge-attach" plan claude # argv, env, files, notesTests: scripts/tests/test_bridge_attach.py (hermetic, throwaway Bridge and repo).
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
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.

