← Commit history

ship.sh: push the skill trees as source too, so a dev-skill edit cannot go stale on the page (found 2026-09-14: two skill fixes existed only on the container)

John Lauer ·9eab75aa50 ·1mo ago ·parent 2d97bd6
1 file changed +16
tools/ship.sh+16
@@ -103,6 +103,21 @@ print(f"   {out}  sha256={hashlib.sha256(open(out,'rb').read()).hexdigest()}  si PY fi +echo "== 2b. STRICT YAML gate on every bundled SKILL.md (#103: a double-quoted description with inner quotes was rejected by Codex; the pkg lint only warned) =="+python3 - <<'PYEOF' || { echo "SHIP ABORTED: a SKILL.md frontmatter does not parse strictly; fix it (description: >- folded scalar) and re-run"; exit 1; }+import glob, re, sys, yaml+bad = []+for p in sorted(glob.glob('skills/*/SKILL.md') + glob.glob('dev-skills/*/SKILL.md') + glob.glob('publish-skills/*/SKILL.md') + ['SKILL.md']):+    m = re.match(r'^---\n(.*?)\n---\n', open(p).read(), re.S)+    if not m: bad.append((p, 'no frontmatter')); continue+    try:+        d = yaml.safe_load(m.group(1))+        if not isinstance(d, dict) or not isinstance(d.get('name'), str) or not isinstance(d.get('description'), str): bad.append((p, 'name/description missing'))+    except Exception as e: bad.append((p, str(e).splitlines()[0][:80]))+for p, why in bad: print('   INVALID', p, '|', why)+print('   strict YAML: %d skill files parsed, %d invalid' % (len(glob.glob('skills/*/SKILL.md')) + len(glob.glob('dev-skills/*/SKILL.md')) + len(glob.glob('publish-skills/*/SKILL.md')) + 1, len(bad)))+sys.exit(1 if bad else 0)+PYEOF echo "== 3a. skills pkg FIRST (a release-born version row never gets the pkg tarball attached: 2.0.398; #66) ==" PUBOUT=$(adom-wiki pkg publish --org adom 2>&1); PUBRC=$? echo "$PUBOUT" | tail -2@@ -177,6 +192,7 @@ PY echo "== 5. push the source text files to the product page (source is open; public manifest untouched) ==" adom-wiki repo push "$PAGE" \   --files src/bridge.json src/BRIDGE_VERSION src/*.js src/extension/*.js src/extension/*.json SKILL.md package.json \+          skills/*/SKILL.md dev-skills/*/SKILL.md publish-skills/*/SKILL.md \   -m "v${VER} (insiders): ${LOG}" >/dev/null 2>&1 || {     [ "${FORCE_PUSH:-0}" = "1" ] || { echo "   PUSH FAILED (set FORCE_PUSH=1 to retry)"; exit 1; }   }