Skip to content

feat(cd): publish to npm - #73

Merged
saltenasl merged 7 commits into
mainfrom
ls/publish-to-npm
Oct 31, 2025
Merged

saltenasl merged 7 commits into
mainfrom
ls/publish-to-npm

Conversation

@saltenasl

@saltenasl saltenasl commented Oct 31, 2025 •

Copy link
Copy Markdown
Contributor

Summary by CodeRabbit

  • Chores
    • Release workflow updated to publish packages to the public npm registry and renamed the publish step to reflect npm.
    • Publishing workflow remains single-package during releases.
  • Documentation
    • Contributing guide updated to reference the current release workflow and the npm-based publish process.

@saltenasl
saltenasl requested a review from a team as a code owner October 31, 2025 08:37
@coderabbitai

coderabbitai Bot commented Oct 31, 2025 •

Copy link
Copy Markdown
Contributor
📝 Walkthrough

Walkthrough

The publish workflow (.github/workflows/cd.yml) was changed to publish to the public npm registry: authentication now uses NPM_TOKEN and the registry URL is registry.npmjs.org instead of npm.pkg.github.com with GITHUB_TOKEN. The job was renamed to "Publish to npm", gained environment: release, and removed GitHub Packages-specific setup and scope binding. CONTRIBUTING.md was updated to reference cd.yml and the npm publishing target.

Sequence Diagram(s)

sequenceDiagram
    participant Workflow as Publish Workflow
    participant OldReg as GitHub Packages (old)
    participant NewReg as npm Registry (new)

    rect rgb(250,250,255)
    Note over Workflow,OldReg: Previous flow
    Workflow->>OldReg: configure npm with GITHUB_TOKEN -> npm.pkg.github.com
    Workflow->>OldReg: pnpm publish --filter ... --no-git-checks
    end

    rect rgb(245,255,245)
    Note over Workflow,NewReg: New flow
    Workflow->>NewReg: configure npm with NPM_TOKEN -> registry.npmjs.org
    Workflow->>NewReg: pnpm publish --filter ... --no-git-checks
    end
Loading

Possibly related PRs

Suggested reviewers

  • andyjakubowski
  • jamesbhobbs
  • Artmann

Pre-merge checks

❌ Failed checks (1 warning)
Check name Status Explanation Resolution
Docstring Coverage ⚠️ Warning Docstring coverage is 0.00% which is insufficient. The required threshold is 80.00%. You can run @coderabbitai generate docstrings to improve docstring coverage.
✅ Passed checks (2 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title Check ✅ Passed The title "feat(cd): publish to npm" directly and accurately describes the primary change in the pull request. The changeset replaces GitHub Packages publishing with npm registry publishing in the CD workflow, and the title clearly captures this intent without vagueness or misleading information. It's concise, specific, and provides immediate context about the modification.

📜 Recent review details

Configuration used: CodeRabbit UI

Review profile: ASSERTIVE

Plan: Pro

Disabled knowledge base sources:

  • Linear integration is disabled by default for public repositories

You can enable these sources in your CodeRabbit configuration.

📥 Commits

Reviewing files that changed from the base of the PR and between b56b4f4 and 0dcd0e8.

📒 Files selected for processing (2)
  • .github/workflows/cd.yml (2 hunks)
  • CONTRIBUTING.md (1 hunks)
🧰 Additional context used
📓 Path-based instructions (1)
**/*.{md,yml,yaml}

📄 CodeRabbit inference engine (CLAUDE.md)

Use Prettier formatting for Markdown and YAML files

Files:

  • CONTRIBUTING.md
🔇 Additional comments (2)
.github/workflows/cd.yml (1)

1-88: Migration to npm publishing is sound; "do not merge" status appropriate pending token setup.

The workflow correctly transitions from GitHub Packages to the public npm registry. Registry configuration, authentication method, and environment isolation are all correct. Past review comments flagging outdated job/step names have been addressed. Once NPM_TOKEN is configured in the release environment, the workflow should work as intended.

CONTRIBUTING.md (1)

121-126: Documentation updated correctly for npm publishing.

Lines 121–126 accurately reflect the workflow changes: correct workflow filename (cd.yml), proper NPM_TOKEN requirement, and appropriate environment placement. Clear and well-integrated with existing publishing guidance.


Comment @coderabbitai help to get the list of available commands and usage tips.

coderabbitai[bot]
coderabbitai Bot previously approved these changes Oct 31, 2025
@codecov

codecov Bot commented Oct 31, 2025 •

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 92.76%. Comparing base (b08def4) to head (0dcd0e8).
⚠️ Report is 4 commits behind head on main.

Additional details and impacted files
@@            Coverage Diff             @@
##             main      #73      +/-   ##
==========================================
- Coverage   92.88%   92.76%   -0.13%     
==========================================
  Files          23       23              
  Lines         773      774       +1     
  Branches      221      221              
==========================================
  Hits          718      718              
- Misses         55       56       +1     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@saltenasl

Copy link
Copy Markdown
Contributor Author

do not merge until I update the token (waiting for the owner to issue it)

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 1

Caution

Some comments are outside the diff and can’t be posted inline due to platform limitations.

⚠️ Outside diff range comments (3)
CONTRIBUTING.md (1)

121-126: Update documentation to reflect npm registry publishing.

Line 121 still references "GitHub Packages" but the workflow now publishes to the public npm registry. This creates confusion for contributors.

-The package will be automatically published to GitHub Packages by the `cd.yml` workflow when the release is published. The workflow:
+The package will be automatically published to npm by the `cd.yml` workflow when the release is published. The workflow:
.github/workflows/cd.yml (2)

7-9: Remove unnecessary GitHub Packages permission.

The packages: write permission is for GitHub Packages and is no longer needed for npm registry publishing.

 permissions:
   contents: read
-  packages: write

12-13: Update job name to reflect npm publishing.

Job name still references "GitHub Packages" but now publishes to npm registry.

     name: Publish to GitHub Packages
+    name: Publish to npm
📜 Review details

Configuration used: CodeRabbit UI

Review profile: ASSERTIVE

Plan: Pro

Disabled knowledge base sources:

  • Linear integration is disabled by default for public repositories

You can enable these sources in your CodeRabbit configuration.

📥 Commits

Reviewing files that changed from the base of the PR and between a88570e and e9cfaab.

⛔ Files ignored due to path filters (1)
  • pnpm-lock.yaml is excluded by !**/pnpm-lock.yaml
📒 Files selected for processing (2)
  • .github/workflows/cd.yml (1 hunks)
  • CONTRIBUTING.md (1 hunks)
🧰 Additional context used
📓 Path-based instructions (1)
**/*.{md,yml,yaml}

📄 CodeRabbit inference engine (CLAUDE.md)

Use Prettier formatting for Markdown and YAML files

Files:

  • CONTRIBUTING.md
🔇 Additional comments (1)
.github/workflows/cd.yml (1)

83-85: Registry configuration looks good.

Correctly configures npm registry and uses NPM_TOKEN for authentication.

Verify that NPM_TOKEN secret is configured in the GitHub repository settings.

Comment thread .github/workflows/cd.yml Resolved
coderabbitai[bot]
coderabbitai Bot previously approved these changes Oct 31, 2025

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 1

Caution

Some comments are outside the diff and can’t be posted inline due to platform limitations.

⚠️ Outside diff range comments (1)
.github/workflows/cd.yml (1)

7-9: Remove unnecessary packages: write permission.

Permission is for GitHub Packages, which is no longer used; only contents: read is needed for checkout.

 permissions:
   contents: read
-  packages: write
📜 Review details

Configuration used: CodeRabbit UI

Review profile: ASSERTIVE

Plan: Pro

Disabled knowledge base sources:

  • Linear integration is disabled by default for public repositories

You can enable these sources in your CodeRabbit configuration.

📥 Commits

Reviewing files that changed from the base of the PR and between 6553aaf and b56b4f4.

📒 Files selected for processing (1)
  • .github/workflows/cd.yml (2 hunks)
🔇 Additional comments (1)
.github/workflows/cd.yml (1)

16-16: Workflow migration looks solid.

Environment context and npm registry configuration are correct. Step name properly updated. Ready once NPM_TOKEN is provided and issue with job naming resolved.

Also applies to: 84-89

Comment thread .github/workflows/cd.yml Resolved
coderabbitai[bot]
coderabbitai Bot previously approved these changes Oct 31, 2025

@Artmann Artmann left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

Comment thread .github/workflows/cd.yml
jobs:
publish:
name: Publish to GitHub Packages
name: Publish to npm

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
name: Publish to npm
name: Publish to NPM

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

npm is typically lowercase
Screenshot 2025-10-31 at 11 20 39
Screenshot 2025-10-31 at 11 20 49

@saltenasl
saltenasl merged commit 7749afa into main Oct 31, 2025
@saltenasl
saltenasl deleted the ls/publish-to-npm branch October 31, 2025 09:21
@coderabbitai coderabbitai Bot mentioned this pull request Oct 31, 2025
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