Add a Node.js CI workflow that builds and tests inside clusterio - #474
Open
bbassie wants to merge 1 commit into
Open
Add a Node.js CI workflow that builds and tests inside clusterio#474bbassie wants to merge 1 commit into
bbassie wants to merge 1 commit into
Conversation
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>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
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:^andcatalog:versions, so they only resolve inside a clusterio checkout with this repository underexternal_plugins. The newnode.ymlworkflow reproduces that layout on the runner: it checks outclusterio/clusteriomaster at the workspace root, checks this repository out intoexternal_plugins/ExpCluster, runspnpm install --no-frozen-lockfile(clusterio does not commit a lockfile, and pnpm refuses to install without one in CI otherwise), which runs everypreparescript, and then runs the tap suites withpnpm --filter "@expcluster/*" run test.The last step is the one that would have caught #473. It wipes every
distfolder and runstsc --buildinside each package on its own.pnpm installbuilds packages in dependency order, so a missing project reference never shows up there. On the commit before #473 this step fails with the same fiveTS2307errors reported in that PR; onmainit passes.The clusterio repository and ref are two
envvalues 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_pluginsand running each step: install 39 s, tests 523 + 575 passing, isolated builds 8 s.🤖 Generated with Claude Code