feat(env): prevent duplicated PATH from fnm env
As previous discussed on #1309 (and maybe somewhere else), the current behavior is to always make a new symlink and append this new folder to PATH.
While I understand this works fine and one usually does not call fnm env multiple times for a shell session, I believe this has room to improve...
I made this change to be less aggressive. I didn't touch other variables and just attacking these two variables that are mutable and related.
On this PR I propose:
-
fnm envwill look forfnm_multishellson the environment variable$PATH.- If found it will not print the
PATHvariable, thus preventing it to be duplicated. - It also uses the value for set
FNM_MULTISHELL_PATH(but stripes out the/bin)
- If found it will not print the
⚠️ No Changeset found
Latest commit: ae2e79297a9e482b3e4066f1c086ac57b3f6ff5a
Merging this PR will not cause a version bump for any packages. If these changes should not result in a new version, you're good to go. If these changes should result in a version bump, you need to add a changeset.
This PR includes no changesets
When changesets are added to this PR, you'll see the packages that this PR includes changesets for and the associated semver types
Click here to learn what changesets are, and how to add one.
Click here if you're a maintainer who wants to add a changeset to this PR
The latest updates on your projects. Learn more about Vercel for Git ↗︎
| Name | Status | Preview | Comments | Updated (UTC) |
|---|---|---|---|---|
| fnm | ✅ Ready (Inspect) | Visit Preview | 💬 Add feedback | Apr 3, 2025 7:40am |