mirror of
https://github.com/microsoft/BCQuality.git
synced 2026-10-05 14:46:55 +01:00
Setup v7: BCQuality knowledge-mirror er maskin-lokal, ikke repo-lokal
- curabis-standard.agent.md v6 -> v7: mirror deployes til ~/.claude/bcquality-knowledge/ (delt af alle repoer paa maskinen) i stedet for .github/.agents/bcquality-knowledge/ i hvert repo - CLAUDE.md-templaten peger paa maskin-mirroren via %USERPROFILE% (aldrig literal udviklersti) og faar self-heal-instruktion - Mode B: v6-aera-oprydning (fjern committet repo-mirror, gitignore stien, foreslaa CLAUDE.md-migrering) + genkend hardcodede udviklerstier og raa-URL-lister som foraeldede CLAUDE.md-former - sync-bcquality-knowledge.ps1: fast destination $env:USERPROFILE \.claude\bcquality-knowledge i stedet for $PSScriptRoot-relativ (det var dobbelttydigheden der skabte repo-mirrors) - Ny regel: bcquality-knowledge-must-mirror-to-machine-not-repo - Setup-artefakter skal fetches som raa bytes (Invoke-WebRequest -OutFile) - aldrig via strengindhold, som dobbelt-encoder UTF-8 Begrundelse: udviklere skifter repo mange gange dagligt; N repo- mirrors er permanent ude af sync, een maskin-mirror kraever een sync pr. upstream-aendring. CI/cloud-agenter henter selv reglerne via .github/bcquality.config.yaml. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
This commit is contained in:
parent
4ee1af5d12
commit
41c6187c4f
3 changed files with 153 additions and 39 deletions
|
|
@ -1,4 +1,4 @@
|
|||
# Refresh the local mirror of the Curabis BCQuality knowledge base.
|
||||
# Refresh the MACHINE-LOCAL mirror of the Curabis BCQuality knowledge base.
|
||||
#
|
||||
# Mirrors three layers from https://github.com/Curabis/BCQuality:
|
||||
# custom/ - Curabis org-specific rules (ALWAYS read in full each session)
|
||||
|
|
@ -11,14 +11,17 @@
|
|||
# keywords from each file's frontmatter) so an agent can scan and pull only the
|
||||
# files relevant to a task instead of loading all ~100 every session.
|
||||
#
|
||||
# Run periodically, then review the diff and commit:
|
||||
# pwsh .github/.agents/sync-bcquality-knowledge.ps1
|
||||
# The mirror is per developer machine (~/.claude/bcquality-knowledge/), shared
|
||||
# by every CURABIS repo on it. It is NEVER committed to a project repository -
|
||||
# see BCQuality rule bcquality-knowledge-must-mirror-to-machine-not-repo.
|
||||
# One sync per machine covers every repo. Run periodically:
|
||||
# powershell -ExecutionPolicy Bypass -File "$env:USERPROFILE\.claude\sync-bcquality-knowledge.ps1"
|
||||
|
||||
$ErrorActionPreference = 'Stop'
|
||||
|
||||
$repo = 'Curabis/BCQuality'
|
||||
$branch = 'main'
|
||||
$dest = Join-Path $PSScriptRoot 'bcquality-knowledge'
|
||||
$dest = Join-Path $env:USERPROFILE '.claude\bcquality-knowledge'
|
||||
$staging = "$dest.tmp"
|
||||
$rawBase = "https://raw.githubusercontent.com/$repo/$branch"
|
||||
$treeUrl = "https://api.github.com/repos/$repo/git/trees/$branch" + '?recursive=1'
|
||||
|
|
@ -121,5 +124,5 @@ Rename-Item -Path $staging -NewName (Split-Path $dest -Leaf)
|
|||
|
||||
Write-Host ''
|
||||
Write-Host "Done. $($files.Count) files across $($layerMap.Count) layers."
|
||||
Write-Host "Review changes with: git diff $dest"
|
||||
Write-Host "Machine-local mirror updated: $dest"
|
||||
exit $rc
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue