feat(create-docusaurus): add nub package manager support - #12309
Draft
colinhacks wants to merge 5 commits into
Draft
feat(create-docusaurus): add nub package manager support#12309colinhacks wants to merge 5 commits into
colinhacks wants to merge 5 commits into
Conversation
✅ [V2]Built without sensitive environment variables
To edit notification comments on pull requests, go to your Netlify project configuration. |
slorber
requested changes
Jul 23, 2026
slorber
left a comment
Collaborator
There was a problem hiding this comment.
Good start but there are many other places that need to be modified in this CLI to properly bring support (types, cli help option description, our docs and maybe more)
Also you may want to add nub as an option in our docs tabs, and for that you need a PR in npm-to-yarn converters first, see for example Deno recently added: bgub/npm-to-yarn#68
slorber
marked this pull request as draft
July 23, 2026 10:15
Contributor
Author
|
Thanks! Addressed:
Let me know if anything else is missing. |
colinhacks
force-pushed
the
create-docusaurus-nub-support
branch
from
July 25, 2026 00:56
2336df8 to
fb25e3c
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Pre-flight checklist
Motivation
Adds nub as a selectable package manager in
create-docusaurus, alongside npm/yarn/pnpm/bun. nub is pnpm-CLI-compatible and writes anub.locklockfile.constants.ts— addnub: 'nub.lock'toLockfileNames. Everything else derives from this map: lockfile detection, the--package-manager nubflag, the interactive prompt, and thePackageManagertype all pick nub up automatically.utils.ts— the script tips relied on npm/yarn/pnpm/bun's implicitstartshortcut (e.g.pnpm start). nub has no implicit script shortcut —nub startis an error — so every tip for nub is explicit:nub run start,nub run build, and so on. The run-prefix logic moved into a smallpackageManagerScriptCommandhelper; output for the existing package managers is unchanged.commands.ts— nub uses the bun-stylenub installand colors from the terminal /FORCE_COLOR; it does not accept the space-separated--color alwaysform the generic branch passes.Test Plan
packageManagerScriptCommand: nub gets an explicitrunon every script; npm/bun keepstartbare but prefixrunelsewhere; yarn/pnpm never prefixrun.nub.locklockfile detection, user-agent detection (npm_config_user_agentisnub/0.4.13 npm/? node/…, matched by the existingstartsWith),nub --versionfor the availability prompt,nub installsucceeds, andnub install --color alwaysfails (the reason for the bun-style branch).