Skip to content

ci(seatmap-lib): add bootstrap publish workflow for first npm release#19

Merged
McSpace merged 1 commit into
mainfrom
dev
Jun 11, 2026
Merged

ci(seatmap-lib): add bootstrap publish workflow for first npm release#19
McSpace merged 1 commit into
mainfrom
dev

Conversation

@McSpace

@McSpace McSpace commented Jun 11, 2026

Copy link
Copy Markdown
Contributor

Summary

Adds a one-shot bootstrap-publish.yml workflow so we can do the very first publish of @seatmaps.com/angular-lib to npm.

Why a separate workflow? npm Trusted Publishing requires the package to already exist on the registry before a Trusted Publisher can be configured on npmjs.com — known limitation tracked at npm/cli#8544. @seatmaps.com/angular-lib is currently 404 on npm, so the existing OIDC-based publish.yml (merged in #17) cannot be the path for release 0.0.1.

bootstrap-publish.yml is identical in shape to publish.yml (same build, same secret-leak guard, same npm-publish environment approval gate, same provenance attestation) but authenticates via the existing repo secret NPM_TOKEN for this one publish. After the first successful run, the admin configures the Trusted Publisher on npmjs.com and a follow-up PR deletes this workflow file so only the OIDC path remains.

INSTRUCTIONS_FOR_ADMIN.md is restructured into two clear flows:

  • A. First-ever release (one-time bootstrap → Trusted Publisher setup → cleanup → eventual NPM_TOKEN revoke)
  • B. Every subsequent release (Trusted Publishing only — version bump → GitHub Release → approve)

Test plan

  • .github/workflows/bootstrap-publish.yml validates with js-yaml
  • No Russian in any code/comment block (project convention)
  • CI green on this PR
  • After merge: admin runs Actions → Bootstrap publish (first npm version only) → Run workflow against main, approves the npm-publish environment gate
  • After merge: npm view @seatmaps.com/angular-lib version returns 0.0.1; package page shows green Provenance badge
  • After merge: admin configures Trusted Publisher on https://www.npmjs.com/package/@seatmaps.com/angular-lib/access (provider GitHub Actions, repo Kwiket/jets-seatmap-angular-lib, workflow publish.yml, environment npm-publish)
  • After merge: follow-up PR deletes .github/workflows/bootstrap-publish.yml
  • After first OIDC release: revoke and delete NPM_TOKEN from repo secrets and npmjs.com

npm Trusted Publishing requires the package to already exist on the
registry before a Trusted Publisher can be configured on npmjs.com
(npm/cli#8544). @seatmaps.com/angular-lib is not yet on npm, so the
very first release cannot go through publish.yml. Adds a one-shot
workflow_dispatch workflow that publishes from main using the existing
NPM_TOKEN repo secret while still attaching Sigstore provenance via
id-token: write. Reuses the npm-publish environment so the same
manual-approval gate applies. INSTRUCTIONS_FOR_ADMIN.md is restructured
into flow A (one-time bootstrap + Trusted Publisher setup) and flow B
(every subsequent OIDC release), with bootstrap-publish.yml scheduled
for deletion in step A5 after the first successful run.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
@McSpace McSpace merged commit 543a44f into main Jun 11, 2026
5 checks passed
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.

2 participants