Repository navigation
fix: load and manage upstream nvm with chezmoi - #39
Merged
Merged
Conversation
Load nvm from ~/.nvm instead of requiring a Homebrew installation. Preserve lazy loading and enable the bundled shell completions.
Fetch the three nvm runtime files from the latest published release without pinning a version or managing installed Node versions. Rename the externals file to make its template syntax explicit.
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.
📝 Summary
Replaces the Homebrew-dependent nvm loader with an upstream nvm installation managed by chezmoi. Removing Homebrew nvm previously disabled the loader even when the official installation was present. Lazy loading and existing
.nvmrcswitching remain unchanged.Key Decisions
Load nvm from its standard installation directory
The loader sets
NVM_DIR=$HOME/.nvmand sources itsnvm.shon first use, without requiring Homebrew. It also loads the optional bundledbash_completion, which supports Zsh.Manage the latest published release through chezmoi
.chezmoiexternal.toml.tmplresolves the latest published nvm release once and downloadsnvm.sh, executablenvm-exec, andbash_completionfrom that same tag. This avoids manual version pins and unreleased development changes. The externals use the existing 168-hour refresh convention; Node versions, aliases, and packages remain outside chezmoi management.🔄 Before & After
~/.nvm.nvmrcswitching