Skip to content

[WIP] Automate npm publication for @node-core/doc-kit package#569

Closed
Copilot wants to merge 1 commit intomainfrom
copilot/automate-npm-publication-doc-kit
Closed

[WIP] Automate npm publication for @node-core/doc-kit package#569
Copilot wants to merge 1 commit intomainfrom
copilot/automate-npm-publication-doc-kit

Conversation

Copy link

Copilot AI commented Jan 27, 2026

Automated npm publication workflow for @nodejs/doc-kit

  • Understand the issue and reference implementation
  • Create publish script (scripts/publish.mjs) to clean package.json and publish
  • Create GitHub Actions workflow for automated publishing
  • Add .npmignore to exclude unnecessary files from npm package
  • Update README with publishing documentation
  • Test the setup
Original prompt

This section details on the original issue you should resolve

<issue_title>Automate npm publication as @node-core/doc-kit with version bump workflow</issue_title>
<issue_description>### Enter your suggestions in details:

Goal: Publish the doc-kit package on npm as @node-core/doc-kit.

Automation: Use a similar workflow for automatically publishing the package on a new version bump as implemented for @node-core/ui-components in the @nodejs/nodejs.org repository.

Details:

  • Automate the npm publish process so that every time a new version of @node-core/doc-kit is released, it is automatically published to npm.
  • Use GitHub Actions to implement this automation, leveraging the workflow already established for @node-core/ui-components in @nodejs/nodejs.org as a reference.
  • The publish.mjs script in ui-components generates a cleaned package.json in dist/, copies documentation, and runs pnpm publish --no-git-checks in the dist directory.
  • The workflow is set up so publishing is triggered on merges to main (after CI success) or via workflow_dispatch. More info and diagrams: docs/package-publishing.md.
  • The monorepo structure supports independent package publishing managed by GitHub Actions.
  • Document any secrets (npm tokens), configuration steps, or permission requirements for publishing—including any changes needed for branch protection, secrets, or CI.

Plan:

  1. Review ui-components publish script and docs.
  2. Adapt a similar workflow and script for use in doc-kit (ensure it strips devDependencies, formats paths, and publishes from dist/).
  3. Create a GitHub Action to trigger the publish job after a version bump, following merge to main or manual trigger—ensure it depends on the successful completion of tests.
  4. Test by bumping @node-core/doc-kit version and verifying an automated npm publish.
  5. Document the setup and maintenance steps in the repository README.

References:

Comments on the Issue (you are @copilot in this section)

@avivkeller I believe we should do `@nodejs/doc-kit`, since this tool is meant to (eventually) be used outside just node core.

✨ Let Copilot coding agent set things up for you — coding agent works faster and does higher quality work when set up for your repo.

@vercel
Copy link

vercel bot commented Jan 27, 2026

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Review Updated (UTC)
api-docs-tooling Ready Ready Preview Jan 27, 2026 11:42am

Request Review

@avivkeller
Copy link
Member

I, uh, did not mean to do that 😭

@avivkeller avivkeller closed this Jan 27, 2026
@avivkeller avivkeller deleted the copilot/automate-npm-publication-doc-kit branch January 27, 2026 11:43
Copilot AI requested a review from avivkeller January 27, 2026 11:43
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.

Automate npm publication as @node-core/doc-kit with version bump workflow

2 participants