Skip to content

fix(mise): pin node on Windows and limit dart to work - #194

Merged
aguil merged 2 commits into
masterfrom
fix/mise-global-node-windows
Nov 23, 2026
Merged

aguil merged 2 commits into
masterfrom
fix/mise-global-node-windows

Conversation

@aguil

@aguil aguil commented Nov 23, 2026 •

Copy link
Copy Markdown
Owner

Why the change

Applying the global mise config on a personal Windows machine would remove Node, which breaks the agents CLI, and install Dart, which only work needs, so the template now pins Node on Windows and limits Dart to the work profile.

Special things to note

  • Node is limited to Windows on purpose: macOS and Linux get it from Homebrew and apt, and a pin there would shadow those.
  • mise.lock keeps its Dart entries for work machines, but mise lock --global on a personal machine prunes them from the installed lock, so that lock should not be copied back into the repo.
  • Applying the template still adds other tools that this machine does not have yet, such as java and yazi.

Change outline

Global mise template:

 bun = "1.3.13"
+{{- if eq .profile "work" }}
 dart = { version = "3.12", ... }
+{{- end }}
 ...
 neovim = "0.12.6"
+# Windows only: macOS and Linux get node from Homebrew and apt. Needed by npm: tools.
+node = { version = "24.14.0", os = ["windows"] }

Which machines get each tool:

 node
-  not in the template
+  Windows, any profile
 dart
-  every profile
+  work profile

Running agents on Windows outside a repo with its own Node, after the template is applied:

 agents
-  node: not found, exit 1
+  node 24.14.0
+    bun 1.3.13
+      runs the CLI

Changed files:

 dot_config/mise/
 ├── config.toml.tmpl   # pins node on Windows, limits dart to work
 └── mise.lock          # adds the Windows node entry

Details

The applied global mise config on Windows has node = "24.14.0", but the template never had node. chezmoi diff shows that applying the template would remove it.

agents (npm:@aguil/agents) starts through Node. With Bun but no Node on PATH, both 0.9.2 and 0.9.3 fail with 'node' is not recognized; with Node 24.14.0 both run.

The pin is limited to Windows because the repo installs Node through Homebrew (Brewfile) and apt (linux/apt-packages.txt) elsewhere. The lock entry covers windows-x64 and windows-x64-baseline only, with the same Windows checksum as the lock already applied on this machine.

The Dart entry is unchanged. It and the comment explaining its http backend moved inside the work profile condition.

Verification (Windows, isolated mise data directory)

  • The template renders for both profiles
  • mise install --dry-run exits 0 for both profiles; Dart is listed for work only, Node for both
  • mise lock --global node adds only the node entry
  • mise install --locked node installs 24.14.0
  • agents --version runs with that Node and Bun
  • chezmoi apply was not run
  • Dart was not installed for real
  • macOS and Linux were not tested locally

🤖 Generated with Claude Code

aguil and others added 2 commits November 22, 2026 17:51
The template had no node, so applying it on Windows would remove the
node 24.14.0 pin from the installed config. `agents` (npm:@aguil/agents)
starts through node and fails without it on PATH.

Limit it to Windows: macOS and Linux get node from Homebrew and apt,
and an unrestricted pin would shadow those. The lock entry covers
Windows only and changes no other tool.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Dart is only needed for work, but the global mise config installed it
on every profile. Render its entry, and the comment explaining its
http backend, only when the chezmoi profile is work.

The shared mise.lock keeps its dart entries for work machines. Running
`mise lock --global` on a personal machine prunes them from the
installed lock, so do not copy that lock back into the source.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@aguil aguil changed the title fix(mise): pin node in the global config on Windows fix(mise): pin node on Windows and limit dart to work Nov 23, 2026
@aguil
aguil marked this pull request as ready for review November 23, 2026 02:39
@aguil
aguil merged commit db44e1b into master Nov 23, 2026
1 check passed
@aguil
aguil deleted the fix/mise-global-node-windows branch November 23, 2026 03:12
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.

1 participant