Skip to content

Add a Node.js CI workflow that builds and tests inside clusterio - #474

Open
bbassie wants to merge 1 commit into
explosivegaming:mainfrom
bbassie:feature/node-ci
Open

Add a Node.js CI workflow that builds and tests inside clusterio#474
bbassie wants to merge 1 commit into
explosivegaming:mainfrom
bbassie:feature/node-ci

Conversation

@bbassie

@bbassie bbassie commented Sep 9, 2026

Copy link
Copy Markdown
Contributor

Follow up to #473. There was no CI for the TypeScript side, so a package that only builds when its siblings happen to be built first went unnoticed until someone hit it on a fresh clone.

The packages use workspace:^ and catalog: versions, so they only resolve inside a clusterio checkout with this repository under external_plugins. The new node.yml workflow reproduces that layout on the runner: it checks out clusterio/clusterio master at the workspace root, checks this repository out into external_plugins/ExpCluster, runs pnpm install --no-frozen-lockfile (clusterio does not commit a lockfile, and pnpm refuses to install without one in CI otherwise), which runs every prepare script, and then runs the tap suites with pnpm --filter "@expcluster/*" run test.

The last step is the one that would have caught #473. It wipes every dist folder and runs tsc --build inside each package on its own. pnpm install builds packages in dependency order, so a missing project reference never shows up there. On the commit before #473 this step fails with the same five TS2307 errors reported in that PR; on main it passes.

The clusterio repository and ref are two env values at the top of the workflow, so pinning to a tag later is a one line change. CONTRIBUTING.md now mentions the build and test run.

Verified locally by cloning clusterio master with ExpCluster main under external_plugins and running each step: install 39 s, tests 523 + 575 passing, isolated builds 8 s.

🤖 Generated with Claude Code

The packages use workspace:^ and catalog: versions, so they only
resolve inside a clusterio checkout with this repository under
external_plugins. The workflow clones clusterio master, checks this
repository out into external_plugins/ExpCluster, runs pnpm install
(which runs every prepare script), then runs the tap suites.

A last step wipes dist and runs tsc --build in each package on its own.
pnpm install builds packages in dependency order, which is why the
missing project references fixed in explosivegaming#473 went unnoticed. On the tree
before explosivegaming#473 this step fails with the same five TS2307 errors.

Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant