ci: fix the PluginDef sanity check (default import, not p.default)
CI / publish (push) Successful in 1m52s
CI / build (push) Successful in 29s

The check imported the default export as `p` and then read `p.default` —
a double-default that is always undefined for a module using
`export default plugin`, so the build job failed on every push (publish
skipped) and v0.2.x never actually published through CI. Read the default
import directly.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
This commit is contained in:
2026-07-19 23:38:20 +02:00
parent e84cc89222
commit e78df91925
+1 -1
View File
@@ -43,7 +43,7 @@ jobs:
run: bunx tsc --noEmit
- name: Sanity — plugin default export is a valid PluginDef
run: |
bun -e 'import p from "./dist/index.js"; const d = p.default; if (d?.name !== "rom-manager" || typeof d?.main !== "function") { console.error("bad default export", d); process.exit(1); } console.log("ok:", d.name)'
bun -e 'import plugin from "./dist/index.js"; if (plugin?.name !== "rom-manager" || typeof plugin?.main !== "function") { console.error("bad default export", plugin); process.exit(1); } console.log("ok:", plugin.name)'
publish:
needs: build