Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix(nushell): cannot switch version #412

Merged
merged 3 commits into from
Feb 24, 2025
Merged

fix(nushell): cannot switch version #412

merged 3 commits into from
Feb 24, 2025

Conversation

bytemain
Copy link
Member

@bytemain bytemain commented Feb 22, 2025

image

@colececil

because here we change the nushell config, so you need to restart twice to make the latest config work, or you will see an error.

@colececil
Copy link
Contributor

colececil commented Feb 24, 2025

Thanks, @bytemain! Switching versions with vfox use is working for me too now with this change. Awesome! 🎉

However, it seems it's still not taking into account .tool-versions files. For example:

~> node --version
v22.12.0
~> cd `Git Repos\`
~\Git Repos> open .tool-versions
nodejs 20.18.3
~\Git Repos> node --version
v22.12.0

And here's the same thing in Git Bash:

~$ node --version
v22.12.0
~$ cd Git\ Repos/
~/Git Repos$ cat .tool-versions
nodejs 20.18.3
~/Git Repos$ node --version
v20.18.3

@colececil
Copy link
Contributor

FYI, I'm also getting intermittent issues with Nushell not finding executables in directories that vfox adds to my path, but I think this is a Nushell issue if I understand correctly. I'm not sure if this behavior is specific to Windows. See my comment at nushell/nushell#7741 (comment).

Copy link
Member

@aooohan aooohan left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM.

@bytemain bytemain merged commit cfc168a into main Feb 24, 2025
3 checks passed
@bytemain
Copy link
Member Author

Thanks, @bytemain! Switching versions with vfox use is working for me too now with this change. Awesome! 🎉

However, it seems it's still not taking into account .tool-versions files. For example:

~> node --version
v22.12.0
~> cd `Git Repos\`
~\Git Repos> open .tool-versions
nodejs 20.18.3
~\Git Repos> node --version
v22.12.0

And here's the same thing in Git Bash:

~$ node --version
v22.12.0
~$ cd Git\ Repos/
~/Git Repos$ cat .tool-versions
nodejs 20.18.3
~/Git Repos$ node --version
v20.18.3

let me check

@colececil
Copy link
Contributor

FYI, I'm also getting intermittent issues with Nushell not finding executables in directories that vfox adds to my path, but I think this is a Nushell issue if I understand correctly. I'm not sure if this behavior is specific to Windows. See my comment at nushell/nushell#7741 (comment).

Based on discussion at the link above, it sounds like the workaround is to use Path with load-env on Windows, while continuing to use PATH on other operating systems. I can get a separate issue created for this, and I should be able to create a pull request this week to fix it.

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.

3 participants