Skip to content

feat: add nub package manager support - #3014

Merged
ghostdevv merged 1 commit into
npmx-dev:mainfrom
2u841r:feat/nub-package-manager
Jul 7, 2026
Merged

feat: add nub package manager support#3014
ghostdevv merged 1 commit into
npmx-dev:mainfrom
2u841r:feat/nub-package-manager

Conversation

@2u841r

Copy link
Copy Markdown
Contributor

Summary

Icon

nub has no standalone logo file in its repo root, but the project's site repo (site/public/icon.svg in nubjs/nub) has one: a black rounded-square badge with a cream "n" glyph and an orange accent dot.

To match the existing icon set's aesthetic (vlt, a11y, etc. in assets/media/custom-icons.json), which are all flat, single-color glyphs that inherit currentColor so they follow the app's theme:

  • Dropped the background square and hardcoded colors (black bg, cream glyph, orange dot)
  • Kept just the "n" glyph + accent dot paths, recolored to fill='currentColor'
  • Cropped the viewBox from the original 0 0 32 32 down to a tight 5 4 23 23 around the glyph's actual bounding box — the original had padding built in for the (now-removed) background square, so without cropping the glyph rendered noticeably smaller than the other PM icons at the same h-3 w-3 size

Test plan

  • test:types passes
  • pnpm test passes (1693/1693 unit + component tests)
  • Verified nub option appears and works in the PM dropdown, install command box, and execute command box locally
  • Reviewer: confirm nub icon renders correctly and matches sizing of other PM icons

Adds nub (https://github.com/nubjs/nub) as a selectable package manager
across the install/execute command builders, the PM dropdown, and the
terminal install/execute displays.
Refs npmx-dev#3013
@vercel

vercelBot commented Jul 6, 2026

Copy link
Copy Markdown
Contributor

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

ProjectDeploymentActionsUpdated (UTC)
npmx.devReadyReadyPreview, CommentJul 6, 2026 3:20pm
2 Skipped Deployments
ProjectDeploymentActionsUpdated (UTC)
docs.npmx.devIgnoredIgnoredPreviewJul 6, 2026 3:20pm
npmx-lunariaIgnoredIgnoredJul 6, 2026 3:20pm

Request Review

@coderabbitai

coderabbitaiBot commented Jul 6, 2026

Copy link
Copy Markdown
Contributor

Review Change Stack

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: Path: .coderabbit.yaml

Review profile: CHILL

Plan: Pro

Run ID: 92d854f2-0189-47f4-b042-fb9f9c1249cf

📥 Commits

Reviewing files that changed from the base of the PR and between 4f3c588 and d7e34eb.

📒 Files selected for processing (7)
  • app/components/Package/ManagerSelect.vue
  • app/components/Terminal/Execute.vue
  • app/components/Terminal/Install.vue
  • app/utils/install-command.ts
  • app/utils/prehydrate.ts
  • assets/media/custom-icons.json
  • test/unit/app/utils/install-command.spec.ts

📝 Walkthrough

Summary by CodeRabbit

  • New Features

    • Added support for an additional package manager, including its install and execute commands.
    • The new package manager icon now appears in the interface when selected.
  • Bug Fixes

    • Improved package-manager selection handling so the new option is recognised from saved preferences and shared links.
    • Updated terminal command displays to show the correct command variant for the new package manager.

Walkthrough

This PR adds "nub" as a supported package manager. It introduces a packageManagers configuration entry, a custom icon asset, prehydration validation for the nub identifier, CSS selector updates across three Vue components to display nub-specific content, and new unit test cases covering install/execute command generation.

Changes

Nub Package Manager Support

Layer / File(s)Summary
Package manager configuration and icon
app/utils/install-command.ts, assets/media/custom-icons.json, app/utils/prehydrate.ts
Adds a nub entry to packageManagers with install/create/execute command metadata (expanding PackageManagerId), adds a nub SVG icon entry, and adds 'nub' to the validPMs set used for prehydration validation.
UI visibility selectors
app/components/Package/ManagerSelect.vue, app/components/Terminal/Execute.vue, app/components/Terminal/Install.vue
Extends data-pm-based CSS selectors so vp and nub command/content variants become visible when selected.
Unit test coverage for nub
test/unit/app/utils/install-command.spec.ts
Adds it.each test rows covering nub for getPackageSpecifier, getInstallCommand, and getExecuteCommandParts, including scoped/unscoped, versioned, dev-dependency, JSR-availability, and create-* scenarios.

Suggested reviewers:ghostdevv

🚥 Pre-merge checks | ✅ 4
✅ Passed checks (4 passed)
Check nameStatusExplanation
Title check✅ PassedThe title clearly and concisely states the main change: adding nub package manager support.
Description check✅ PassedThe description is directly related to the nub support changes and matches the implemented scope.
Linked Issues check✅ PassedThe changes implement nub support in command builders, selectors, prehydrate validation, icon assets, and tests as requested in #3013.
Out of Scope Changes check✅ PassedNo clearly out-of-scope changes are evident; the icon, UI, logic, and tests all support nub package manager integration.
✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

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

@codecov

codecovBot commented Jul 6, 2026

Copy link
Copy Markdown

Codecov Report

❌ Patch coverage is 0% with 1 line in your changes missing coverage. Please review.
✅ All tests successful. No failed tests found.

Files with missing linesPatch %Lines
app/utils/prehydrate.ts0.00%1 Missing ⚠️

📢 Thoughts on this report? Let us know!

@ghostdevv
ghostdevv added this pull request to the merge queueJul 7, 2026
Merged via the queue into npmx-dev:main with commit 96c8986Jul 7, 2026
25 checks passed
@github-actions

Copy link
Copy Markdown

Thanks for your first contribution, @2u841r! ⭐

We'd love to welcome you to the npmx community. Come and say hi on Discord! And once you've joined, visit npmx.wamellow.com to claim the contributor role.

@github-actionsgithub-actionsBot mentioned this pull request Jul 7, 2026
ayo-run pushed a commit to ayo-run/npmx.dev that referenced this pull request Aug 5, 2026
Sign up for freeto 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.

Add support for nub package manager

2 participants

@2u841r@ghostdevv