Skip to content

feat(claude): ship a git-workflow skill alongside bodhi-compute - #6

Merged
jayhesselberth merged 1 commit into
mainfrom
worktree-git-workflow-skill
Aug 26, 2026
Merged

jayhesselberth merged 1 commit into
mainfrom
worktree-git-workflow-skill

Conversation

@jayhesselberth

Copy link
Copy Markdown
Member

Git work happens inside sinteractive sessions, and an agent starting one has no
standing guidance about how it should be done — so it re-derives the
conventions each time, or guesses. bodhi-compute already solved the same
problem for cluster etiquette; this rides the rails it established and reaches
every session on every node with no per-session setup.

The skill

skills/git-workflow/SKILL.md is deliberately general — it names no project,
and defers to any repository that documents something stricter of its own:

  • Worktree per branch, at <repo>/.claude/worktrees/<name>, with a note on
    what worktree.baseRef chooses and to ignore the directory.
  • Land through a pull request — nothing goes onto main directly, and no
    force-pushing shared branches.
  • Conventional Commits — the standard type set, optional scope, and a body
    that explains why rather than restating the diff.
  • Semantic versioning with annotated vX.Y.Z tags, including the pre-1.0
    shift and why a lightweight tag is not good enough.
  • Releasing — find every place the version is written before changing any
    of them, then roll the changelog and tag.
  • Run the repo's own CI gates before pushing, and put heavy ones in their
    own allocation (cross-referencing bodhi-compute).

Why the installer changed

A second skill meant the installer could no longer name what it ships.
--install-claude now copies every skills/*/SKILL.md found beside the
script, and the Makefile installs the tree from a $(SKILLS) wildcard rather
than one hardcoded path per target.

skills/bodhi-compute appeared in six places — the script, install-user,
install-system, and both branches of the nodes fan-out. Any one of them
missed on the next skill would have shipped a partial set to the compute
nodes, where the gap stays invisible until somebody runs --install-claude
from inside a session and gets the older half. Adding a skill is now dropping
a directory into skills/.

find_claude_assets still probes for skills/bodhi-compute rather than
skills/, so an empty skills/ left by a half-finished install does not pass
for a complete one.

Verification

All four validate.yml gates run clean locally (bash -n, shellcheck --severity=warning, groff -ww -z, json.tool). Beyond that:

  • --install-claude into a throwaway CLAUDE_CONFIG_DIR lands both
    skills/*/SKILL.md plus the hooks, at the right modes; a second run reports
    the hooks already registered and leaves settings alone.
  • make install-user into a temp prefix produces the expected share/ tree,
    and --install-claude run from that installed copy discovers it through
    bin/../share/sinteractive.
  • make -n nodes expands correctly on both branches; the tar-fallback skill
    loop was exercised against a real tarball into a temp destination.

🤖 Generated with Claude Code

Git work happens in sinteractive sessions, and an agent starting one has no
standing guidance about how it should be done — so it re-derives the
conventions every time, or guesses. bodhi-compute already solved the same
problem for cluster etiquette; this rides the rails it established and reaches
every session on every node with no per-session setup.

The skill is deliberately general: semantic versioning with annotated vX.Y.Z
tags, Conventional Commit messages, one worktree per branch under
.claude/worktrees/, landing through a pull request rather than committing to
main, and running the repo's own CI gates before pushing. It names no project
and defers to a repository that documents something stricter of its own, so it
is useful in whatever checkout the session happens to be sitting in.

Adding it meant the installer could no longer name what it ships.
--install-claude now copies every skills/*/SKILL.md found beside the script,
and the Makefile installs the whole tree from a $(SKILLS) wildcard rather than
one hardcoded path per target. skills/bodhi-compute appeared in six places
across the script, install-user, install-system and both branches of the nodes
fan-out; any one of them missed on the next skill would have shipped a partial
set to the compute nodes, where the gap is invisible until someone runs
--install-claude from inside a session and gets the older half.

find_claude_assets still probes for skills/bodhi-compute rather than skills/,
so an empty skills/ from a half-finished install does not pass for a complete
one.

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
@jayhesselberth
jayhesselberth merged commit 5c2d3bc into main Aug 26, 2026
1 check passed
@jayhesselberth
jayhesselberth deleted the worktree-git-workflow-skill branch August 26, 2026 12:15
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant