v19: git-baseret konsumtion - forberedelse til privat repo

Beslutning: BCQuality skal vaere privat. En fork af et offentligt repo
kan ikke goeres privat, saa flyttet sker via detach/nyoprettelse - men
FOERST omlaegges al konsumtion fra tokenfri raw-URLs til git-baseret
adgang, shippet mens kanalen stadig er offentlig, saa flaaden aldrig
oplever et hul. GCM er token-haandteringen: udviklerne er allerede
autentificeret.

Kernen er KANAL-KLONEN: %USERPROFILE%\.claude\BCQuality, pinned til
stable. Alt kopieres derfra (filsystem-kopi = raa bytes; ingen
CDN-cache, ingen API-limits).

- sync-bcquality-knowledge.ps1 v2: git-baseret (klon/fetch/checkout
  stable, mirror bygges lokalt, skriver selv versionsmarkoeren)
- Install-CurabisMachine.ps1 v2: onboarding = git clone + script fra
  klonen; foerste GCM-login ER autentificeringen
- curabis-standard.agent.md v19: SRC/BASE-tokens peger paa klonen;
  fetch betyder copy; Mode B Step 0 freshener klonen; ny Mode B-
  sektion opdaterer maskin-CLAUDE.md ved konsumtionsmodel-skift
  (gated, Identity bevares); CLAUDE.md-templatens self-heals er
  git-baserede
- machine/CLAUDE.md v2: auto-update gater paa git fetch/rev-parse
  i stedet for GitHub API; setup laeses fra klonen
- Ishikawa + al-triage + Francis: fallbacks peger paa mirror/klon;
  al-triages hardcodede URL-liste fjernet (samme sygdom som Ishikawa
  havde). Aerlig konsekvens: Copilot mister live custom-fallback
- CONSUMPTION.md: Access model-sektion + to-linjers onboarding
- Invoke-CurabisEvidence: RawBase markeret legacy/doed

Nul raw.githubusercontent-referencer tilbage i forbrugerkritiske filer.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
This commit is contained in:
Michael Dieringer 2026-07-03 17:44:19 +02:00
parent a95cf7f43f
commit 3ce08fe91e
9 changed files with 205 additions and 139 deletions

View file

@ -56,14 +56,11 @@ Loop: **reproduce -> root-cause -> minimal-fix recommendation.**
Layer 1 - Microsoft BCQuality: https://github.com/microsoft/BCQuality
Layer 2 - CURABIS custom knowledge (fetch before citing a finding):
- https://raw.githubusercontent.com/Curabis/BCQuality/stable/custom/knowledge/architecture/pages-must-not-contain-business-logic.md
- https://raw.githubusercontent.com/Curabis/BCQuality/stable/custom/knowledge/architecture/namespace-must-be-verified-from-source.md
- https://raw.githubusercontent.com/Curabis/BCQuality/stable/custom/knowledge/architecture/al-identifiers-must-be-english.md
- https://raw.githubusercontent.com/Curabis/BCQuality/stable/custom/knowledge/architecture/clarify-before-building.md
- https://raw.githubusercontent.com/Curabis/BCQuality/stable/custom/knowledge/testing/test-setup-must-use-library-codeunit.md
- https://raw.githubusercontent.com/Curabis/BCQuality/stable/custom/knowledge/testing/test-data-must-be-random-and-complete.md
- https://raw.githubusercontent.com/Curabis/BCQuality/stable/custom/knowledge/testing/tests-must-adapt-to-existing-code.md
Layer 2 - CURABIS custom knowledge: read from the machine-local mirror —
`%USERPROFILE%\.claude\bcquality-knowledge\custom\` (always complete; never a
hardcoded file list — the rulebook grows). Fallback without a mirror: the
channel clone at `%USERPROFILE%\.claude\BCQuality\custom\knowledge\`. The
repo is PRIVATE — raw URLs do not exist.
If a source is unreachable, **degrade gracefully**: fall back to the triage protocol
below plus the CURABIS-ARCH rules in `bcquality.agent.md`, note that BCQuality was

View file

@ -54,10 +54,13 @@ Resolve the current rule set at review time, in this order:
`~/.claude/bcquality-knowledge/custom/` (Windows:
`%USERPROFILE%\.claude\bcquality-knowledge\custom\`). The mirror is synced
from the `stable` release channel and is always the complete custom layer.
2. **Fallback (no mirror — Copilot, fresh machine, CI):** list the tree via
`https://api.github.com/repos/Curabis/BCQuality/git/trees/stable?recursive=1`
filtered to `custom/knowledge/**/*.md`, and fetch each file from
`https://raw.githubusercontent.com/Curabis/BCQuality/stable/<path>`.
2. **Fallback (no mirror):** read directly from the machine's channel clone —
`%USERPROFILE%\.claude\BCQuality\custom\knowledge\**\*.md` (freshen with
`git -C "$env:USERPROFILE\.claude\BCQuality" pull` if stale). The repo is
PRIVATE: tree-API/raw-URL fallbacks no longer exist. Consumers without
filesystem access outside the workspace (e.g. Copilot) rely on the
repo-committed agent files alone — deep custom-layer lookups happen in
Claude Code sessions.
Relevance filtering: `custom/` rules are always active in CURABIS repos — read
them all; use each file's frontmatter `domain`/`keywords` only to prioritize,