fix(census,install): moved dirs scanned, real-dir remedy, impeccable adoption, retired list carries its rationale
Census scans the four moved dirs and bare skills/<n>/ citers, warns on a pack id with no manifest, refuses equal fragments. Installers adopt a real skills/impeccable with mv, never rm.
This commit is contained in:
1 parent
9baba8a88a
commit
9327b4fcd0
12 files changed
+91
-28
No files matched your search
@@ -186,14 +186,15 @@ citers_check_files "$FIX" "$FIX/t2.md" >/dev/null
|
||||
check T8h-template-rules-path "$rc1|$?" "0|1"
|
||||
|
||||
# ── real census: the repo's own citers against CLAUDE.global.md ──────────────
|
||||
# (`impeccabl[e]` is a glob: the pack census must not read it as a citer.)
|
||||
mapfile -t FILES < <(cd "$ROOT" && find skills agents lib rules hooks -type f \( -name '*.md' -o -name '*.sh' \) \
|
||||
-not -path 'skills/graphify/*' -not -path 'skills-external/impeccable/*' -not -path 'skills/synced/*' \
|
||||
-not -path 'skills/graphify/*' -not -path 'skills/impeccabl[e]/*' -not -path 'skills-external/impeccable/*' -not -path 'skills/synced/*' \
|
||||
-not -path 'agents/impeccable-*' -not -path 'lib/tests/*' | sort)
|
||||
# T6 also scans the templates and this repo's own project rules; T3 must not
|
||||
# (there `CLAUDE.md` means a project CLAUDE.md, not the doctrine).
|
||||
mapfile -t FILES_ALL < <(cd "$ROOT" && find skills agents lib rules hooks \
|
||||
templates .claude/rules -type f \( -name '*.md' -o -name '*.sh' \) \
|
||||
-not -path 'skills/graphify/*' -not -path 'skills-external/impeccable/*' \
|
||||
-not -path 'skills/graphify/*' -not -path 'skills/impeccabl[e]/*' -not -path 'skills-external/impeccable/*' \
|
||||
-not -path 'skills/synced/*' -not -path 'agents/impeccable-*' \
|
||||
-not -path 'lib/tests/*' | sort)
|
||||
# T8f: the T6 list reaches the two blind trees, the T3 list does not
|
||||
|
||||
@@ -53,8 +53,12 @@ mv "$FX/skills/pack-alpha/.claude-plugin/plugin.json.bak" "$FX/skills/pack-alpha
|
||||
|
||||
ln -s ../skills-external/a1 "$FX/skills/a1"
|
||||
out="$(census)"; rc=$?
|
||||
check T5-dup-rc "$rc" 1; check_has T5-dup "$out" "RED a1 listed twice: skills/a1 and pack-alpha — rm skills/a1 (a flat link)"
|
||||
check T5-dup-rc "$rc" 1; check_has T5-dup "$out" "RED a1 listed twice: skills/a1 and pack-alpha; run: rm skills/a1 (a flat link)"
|
||||
rm "$FX/skills/a1"
|
||||
mkdir "$FX/skills/a1"; touch "$FX/skills/a1/SKILL.md"
|
||||
out="$(census)"
|
||||
check_has T5-dup-real "$out" "run: mv skills/a1 skills-external/a1 (a real dir)"
|
||||
rm -r "$FX/skills/a1"
|
||||
|
||||
ln -s "../../../skills-external/a1" "$FX/skills/pack-alpha/skills/gs-dead"
|
||||
out="$(census)"; rc=$?
|
||||
@@ -91,6 +95,17 @@ out="$(census)"; rc=$?
|
||||
check T10-fixed-rc "$rc" 1; check_has T10-fixed "$out" "RED lib/profiles/dev.json: security-guidance@claude-code-plugins must be true"
|
||||
mv "$FX/lib/profiles/dev.json.bak" "$FX/lib/profiles/dev.json"
|
||||
|
||||
# identical fragments; a pack id with no manifest (WARN, not RED)
|
||||
cp "$FX/lib/profiles/dev.json" "$FX/lib/profiles/zdev.json"
|
||||
out="$(census)"; rc=$?
|
||||
check T13-same-rc "$rc" 1
|
||||
check_has T13-same "$out" "RED lib/profiles/dev.json and zdev.json are identical fragments"
|
||||
rm "$FX/lib/profiles/zdev.json"
|
||||
sed 's/pack-beta@skills-dir": false/pack-beta@skills-dir": false, "pack-ghost@skills-dir": false/' "$FX/lib/profiles/dev.json" > "$FX/lib/profiles/ghost.json"
|
||||
out="$(census)"; rc=$?
|
||||
check_has T14-ghost "$out" "WARN lib/profiles/ghost.json: names pack-ghost with no skills/pack-ghost/"
|
||||
rm "$FX/lib/profiles/ghost.json"
|
||||
|
||||
# real repo, hermetic part
|
||||
out="$(bash "$ROOT/lib/pack-census.sh" 2>&1)"; rc=$?
|
||||
check T11-real-rc "$rc" 0; check_has T11-real "$out" "PACKS OK 9 packs 55 skills"
|
||||
|
||||
@@ -15,8 +15,8 @@ has() { if grep -qF "$2" "$R/$1"; then ok; else ko "$1 missing: $2"; fi; }
|
||||
SEO=agents/seo-analyzer.md
|
||||
GEO=agents/geo-analyzer.md
|
||||
|
||||
# 1) judge verdict grammar — DISPATCHER ERROR CONTRACT (skills/seo STEP 1,
|
||||
# skills/geo STEP 1B) fail-closes on this exact shape
|
||||
# 1) judge verdict grammar — DISPATCHER ERROR CONTRACT (skills/pack-seo/skills/seo STEP 1,
|
||||
# skills/pack-seo/skills/geo STEP 1B) fail-closes on this exact shape
|
||||
has "$SEO" 'SEO JUDGE — VERDICT: ERROR('
|
||||
has "$GEO" 'GEO JUDGE — VERDICT: ERROR('
|
||||
has "skills/pack-seo/skills/seo/SKILL.md" 'SEO JUDGE — VERDICT: ERROR('
|
||||
|
||||
Reference in new issue
Block a user