feat(upgrade): add mise install channel - #571
Conversation
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
There was a problem hiding this comment.
ℹ️ No critical issues — one docs consistency gap worth a look.
Reviewed changes — the initial submission of a new mise install channel for nub upgrade, so a mise-managed nub upgrades through mise itself instead of getting misrouted to npm install -g.
- Route mise before the
node_modulesrung —detect_mise_installruns ahead of the Npm check indetect_channel, so the npm-backend layout (…/mise/installs/npm-nubjs-nub/<ver>/…/node_modules/…) classifies asMiserather than planting a shadowing global copy. - Detect both layouts — a pure path-component scan maps the
nubandnpm-nubjs-nubinstalls-dir slugs to the mise tool idsnub/npm:@nubjs/nubviamise_tool_for_slug; unknown slugs fall through toUnknown. - Delegate the upgrade to mise —
perform_mise_upgradereads the pinning config frommise ls --json <tool>(parse_mise_ls_source), resolveslatestto a concrete version, then runsmise use --path <config> <tool>@<ver>to install and rewrite the pin. - Extend the canary gate — mise joins Homebrew/winget as a stable-only channel, so a canary ask routes to the standalone installer.
- Tests — pure functions unit-tested for both layouts, npm-backend-over-
node_modulesprecedence, and themise lsmatch/fallback/no-source/non-array cases.
I verified the load-bearing mise CLI contracts against jdx/mise's current source: mise ls --json <tool> is a bare array (the tool positional takes an early-return branch), source.path names the pinning config, mise use --path <file> writes the pin to that exact file and installs if missing, npm:@nubjs/nub slugs to npm-nubjs-nub, and the npm backend resolves only from the semver version list so canary genuinely can't be served. The routing logic and its precedence over the node_modules rung are correct. The only gap is a docs update that AGENTS.md requires for a user-facing behavior change.
ℹ️ FAQ still names only Homebrew and winget as stable-only channels
The upgrade FAQ tells canary users that "Homebrew and winget carry only stable releases, so upgrading through them always lands on a release." This PR makes mise a third channel with exactly that behavior — the canary gate now bails on Homebrew | Winget | Mise alike — so the sentence is now incomplete for mise-installed users.
Technical details
# FAQ omits mise from the stable-only upgrade channels
## Affected sites
- `site/content/docs/faq.mdx:414` — "Homebrew and winget carry only stable releases, so upgrading through them always lands on a release." mise is now a stable-only channel too (the canary gate in `crates/nub-cli/src/cli.rs:6040` matches `Homebrew | Winget | Mise`).
## Required outcome
- The sentence names mise alongside Homebrew and winget as a stable-only channel.
## Suggested approach (optional)
- Change to "Homebrew, winget, and mise carry only stable releases, …". Optionally, the upgrade instructions at `faq.mdx:373` ("match how you installed … otherwise re-run your installer") could note that a mise install now upgrades in place via `nub upgrade`, but that is a softer nicety, not a correction.Claude Opus | 𝕏
|
Addressed: the FAQ now names mise alongside Homebrew and winget as a stable-only channel, and the upgrade answer notes that a mise-managed install upgrades in place via |
35da944 to
0b4ef6e
Compare
There was a problem hiding this comment.
✅ No new issues found.
Reviewed changes — the delta since the prior pullfrog review is the docs commit that closes out that review's sole finding, plus a rebase of the feature commit onto current main.
- Named mise among the stable-only upgrade channels — the canary paragraph now reads "Homebrew, winget, and mise carry only stable releases", matching the canary gate in
crates/nub-cli/src/cli.rs:6114, which bails onHomebrew | Winget | Mise { .. }alike. - Documented the in-place mise upgrade path — the upgrade answer now tells a mise-managed install to use
nub upgrade, which delegates to mise and rewrites the version pin, rather than leaving it under the generic "re-run your installer". - Rebased the feature commit onto
main—85ae7bb4is a byte-identical replay of the previously reviewed35da9444(same single file, same +294/-9), so the mise routing,mise ls --jsonparsing, andmise use --pathdelegation carry no code delta.
I re-verified both new sentences against the implementation rather than the PR description: the canary claim matches the gate's matches! arm, and the pin-rewrite claim matches perform_mise_upgrade running mise use --path <config> <tool>@<version>. I also swept the rest of the docs for stale channel copy — site/content/docs/faq.mdx is the only page carrying channel-specific upgrade guidance, and the mise use -g nub / mise use nub@latest snippets in docs/index.mdx, README.md, and docs/deployment/index.mdx all install the registry nub tool, whose installs-dir slug detect_mise_install already covers.
Claude Opus | 𝕏

nub upgrademisrouted mise installs: the npm-backend layout containsnode_modules, so it hit the npm channel andnpm install -gplanted a second global copy that shadows the mise shim.installs/nub/…,installs/npm-nubjs-nub/…) before thenode_modulesrung.mise ls --json <tool>finds the pinning config,mise use --path <config> <tool>@<resolved>installs + rewrites the pin.Unit tests cover both layouts and
mise lsparsing; dry-run + real upgrade from a mise install verified manually.