build: drop docker-bake in favor of plain npm#551
Merged
Conversation
Every TypeScript action maintained by actions/* (checkout, setup-node, setup-go, cache, upload-artifact) uses plain npm scripts. The bake setup is a docker/* org convention and adds friction for TS work: contributors need Docker, the dev loop is ~10x slower than npm, and Alpine-vs-host byte drift in dist/index.js makes PRs bounce. Replace with the standard pattern: - .node-version pins Node 24 so contributors and CI agree - npm scripts (build, lint, format, test, pre-checkin) replace bake targets one-for-one - validate.yml runs lint + a check-dist diff (mirrors actions/setup-node) and a vendor check that npm install --package-lock-only is a no-op - test.yml uses setup-node + sigstore/cosign-installer, drops bake-action - dependabot-build.yml regenerates dist via npm instead of bake CONTRIBUTING.md and README development section updated to match. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Match the standard layout used by actions/checkout, actions/setup-node, etc.: - package.json scripts: split format/format-check (Prettier) from lint/lint:fix (ESLint), and have pre-checkin run all four (format, lint:fix, build, test) in that order. - validate.yml lint job runs format-check + lint as separate steps. - test.yml drops the redundant --coverage flag (now in the test script). - Drop dependabot-build.yml: actions/* don't auto-rebuild dist on dependabot PRs; the check-dist style validate / build job catches drift and a maintainer rebuilds locally if needed. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.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.
Replaces the
docker buildx bakedev workflow with plainnpmscripts, matching every TS action maintained byactions/*(checkout, setup-node, setup-go, cache, upload-artifact). The bake setup is adocker/*org convention that adds friction for a TypeScript action: contributors need Docker, the dev loop is ~10x slower than npm, and Alpine-vs-host byte drift indist/index.jsmakes PRs bounce.Changes
.node-versionpins Node 24 (same versiondev.Dockerfileused) so contributors and CI agree on bundler output.package.jsongains apre-checkinscript (format+build+test) — the npm equivalent of the old bake target..github/workflows/validate.ymlrewritten as native npm jobs:lint—npm run lintbuild—npm run buildthengit diff --ignore-space-at-eol dist, mirroring theactions/reusable-workflowscheck-dist pattern. Uploads the rebuiltdist/as an artifact on failure so contributors can grab it.vendor—npm install --package-lock-onlythengit status, replacingbake vendor-validate..github/workflows/test.ymlusesactions/setup-node+sigstore/cosign-installer+npm testinstead ofdocker/bake-action..github/workflows/dependabot-build.ymlregeneratesdist/via npm instead of bake.dev.Dockerfileanddocker-bake.hcldeleted.CONTRIBUTING.mdand README Development section updated.Verification
npm ci && npm run build && npm run lint && npm testall pass.dist/index.jseven on Node 25 / macOS — the bundler output is reproducible across hosts.v0.182.0-proDarwin is a release-tarball quirk, not related to this change; CI runs on ubuntu-latest).