Plexus icon indicating copy to clipboard operation
Plexus copied to clipboard

Enable fully automated npm publishing via Trusted Publishing

Open miniLV opened this issue 7 months ago • 1 comments

Context

The repository now has the release automation pieces in place:

  • scripts/release-npm.mjs verifies the exact npm tarball before publish.
  • .github/workflows/publish-npm.yml is wired to publish on v*.*.* tags.
  • v0.0.4 was pushed and [email protected] was manually published after the GitHub Actions publish job failed.
  • Local and registry smoke tests passed for npm install plexus-agent-config@latest, plexus detect, and plexus start.

The remaining gap is npm account/package-side configuration for fully automatic publishing.

Tasks

  • [ ] In npmjs.com, open plexus-agent-config package settings.
  • [ ] Add a Trusted Publisher for GitHub Actions:
    • Organization/user: miniLV
    • Repository: Plexus
    • Workflow filename: publish-npm.yml
    • Environment: leave empty unless GitHub environments are added later.
  • [ ] Re-run the failed publish npm workflow or validate on the next tag.
  • [ ] Confirm the workflow publishes without NPM_TOKEN.
  • [ ] Confirm npm view plexus-agent-config version dist-tags.latest matches the Git tag/package version.
  • [ ] Confirm a clean install works: npm install plexus-agent-config@latest && npx plexus-agent-config@latest start.
  • [ ] Optional: after Trusted Publishing works, consider npm package setting "Require two-factor authentication and disallow tokens".

Notes

Do not tag future releases as v0.02. Keep semver aligned as package.json version 0.0.x and Git tag v0.0.x.

miniLV avatar May 01 '26 15:05 miniLV

Done.

  • npm Trusted Publishing is configured for miniLV/Plexus and .github/workflows/publish-npm.yml.
  • v0.0.7 was published by GitHub Actions without NPM_TOKEN.
  • npm view plexus-agent-config version dist-tags.latest returns 0.0.7.
  • Clean install smoke test passed with npm install plexus-agent-config@latest, plexus help, plexus detect, and plexus start returning HTTP 200.

Closing this as complete.

miniLV avatar May 06 '26 00:05 miniLV