From 5078eb0709d811e3b31aad4011093ddde1e74a66 Mon Sep 17 00:00:00 2001 From: Bastien Chanot Date: Mon, 6 Jul 2026 02:33:56 +0200 Subject: [PATCH] =?UTF-8?q?job1:=20F1=20density=20pass=20=E2=80=94=20gitfl?= =?UTF-8?q?ow=20section=2036=E2=86=9224=20lines,=20all=20constraints=20pre?= =?UTF-8?q?served?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- CLAUDE.md | 54 +++++++++++++++++++++--------------------------------- 1 file changed, 21 insertions(+), 33 deletions(-) diff --git a/CLAUDE.md b/CLAUDE.md index 2020ca1..a293e0c 100644 --- a/CLAUDE.md +++ b/CLAUDE.md @@ -163,40 +163,28 @@ All web API endpoints must be versioned from day one: `/api/v1/...`. ## Version control — gitflow (universal) -Every git action follows gitflow — inside a skill AND for ad-hoc commits made -outside one on direct request. The model is universal across all projects. +Every git action follows gitflow — in a skill, or an ad-hoc commit made outside +one on request. `main` (prod) · `develop` (integration, off main) · `feature/*` + `bugfix/*` + `chore/*` (off develop → develop; `chore/*` = memory/doc +maintenance, e.g. standalone `/capitalize` `/close` `/prune-memory` +`/reconcile`) · `release/*` (off develop → main + back-merge develop) · +`hotfix/*` (off main → main + develop [+ any open release/*]). `master`→`main` +everywhere. -### Branch model -`main` (prod) · `develop` (integration, off main) · `feature/*` + `bugfix/*` + -`chore/*` (off develop → develop; `chore/*` = memory/doc maintenance, e.g. -standalone `/capitalize` `/prune-memory` `/reconcile`) · `release/*` (off develop → -main + back-merge develop) · `hotfix/*` (off main → main + develop [+ any open -release/*]). `master`→`main` everywhere. - -### Rules for every git action -- **Never commit code directly on `main` or `develop`.** Branch first from the - correct base, named `/`. (`.claude/**` memory/config commits are - hook-exempt — they follow the work; but *standalone* memory/doc skills branch to - `chore/*` via the aiguillage rather than lean on that exemption.) -- **Branch + merge via the lib, never by hand** — the directed-merge + hotfix - fan-out logic lives there once: - `bash ~/.claude/lib/gitflow.sh start ` · `… finish`. -- **`gitflow finish` (merge) only on an explicit human signal** ("merge it", - "feature OK") — never because tests pass, a plan step says "merge", or a verb - ("ship") implied it. -- **Assistance flows** (`/feat` `/bugfix` `/hotfix`) AND **standalone memory/doc - skills** (`/capitalize` `/close` `/prune-memory` `/reconcile`, type `chore`) - auto-branch on a protected base (the aiguillage); on a working branch they commit - in place, never finish. -- **New/onboarded projects** get the model + the versioned pre-commit hook via - `gitflow init` (init-project STEP 5f, onboard STEP 2.6). - -### Enforcement layers -Advisory — it can be forgotten on a long conversation (no reliable oracle). The -deterministic backstops are the per-repo **pre-commit hook** (`gitflow init` -installs it: blocks code commits on main/develop, exempts `.claude/**` + merges + -the root commit) and **Gitea branch protection** on `main`/`develop` (set up by -the migration). Don't lean on `--no-verify` to bypass them. +Never commit code directly on `main` or `develop`: branch first from the +correct base as `/` (`.claude/**` memory/config commits are +hook-exempt, following the work). Branch/merge only via the lib, never by hand: +`bash ~/.claude/lib/gitflow.sh start ` · `… finish`. Run `finish` +(merge) only on an explicit human signal ("merge it", "feature OK"), never +because tests pass, a plan step says "merge", or "ship" implied it. Assistance +flows (`/feat` `/bugfix` `/hotfix`) and the standalone memory/doc `chore` +skills auto-branch on a protected base but commit in place on a working branch, +never finishing — so those skills branch to `chore/*` via the aiguillage, not +the `.claude/**` exemption. New/onboarded projects get the model + the +versioned pre-commit hook via `gitflow init`. Advisory, so two deterministic +backstops apply: the per-repo pre-commit hook (blocks code commits on +main/develop, exempts `.claude/**` + merges + the root commit) and Gitea branch +protection on `main`/`develop`. Don't lean on `--no-verify` to bypass them. ## Security — non-negotiable defaults