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

Document method to return to system node #39

Closed
hildjj opened this issue Nov 9, 2016 · 7 comments
Closed

Document method to return to system node #39

hildjj opened this issue Nov 9, 2016 · 7 comments
Labels
enhancement New feature or fix

Comments

@hildjj
Copy link

hildjj commented Nov 9, 2016

If there is a mechanism to turn fnm off, it doesn't seem to be documented.

@hildjj
Copy link
Author

hildjj commented Nov 9, 2016

fnm rm (node -v) worked. Suggest this gets doc'd.

@maparent
Copy link

maparent commented Sep 7, 2018

I tried removing (on mac) and it still uses the old binary that was copied in ~/.config/fnm/bin/node
Also it means if I go back and forth between system and specific version it must re-download. Not that enthusiastic about that solution.
As for selecting the previous version, it's the fnm copy of my system node, which may not be the system node. (For one thing, the latter gets updated semi-automatically.)
So I'd really appreciate a fnm system command.

@jorgebucaran
Copy link
Owner

@hildjj @maparent The new version of this package will not have a rm command (at first), so the only way to get back to system node is to uninstall this package.

Is this something you do often? If so, I can work on a system or default alias to do just that.

@jorgebucaran jorgebucaran added enhancement New feature or fix Discussion labels Jan 9, 2019
@hildjj
Copy link
Author

hildjj commented Jan 9, 2019

Candidly, I went back to zsh. However, I'm happy to talk through my use case.

I develop with a system-installed nodejs (via homebrew on OSX). I like that it stays up-to-date when I update the rest of my local stack. Periodically (usually when I get a CI failure on an older version of Node), I want to drop down to a given version, debug, then go back to the most recent version.

@jwhitmarsh
Copy link

Apologies if this is the wrong place for this, but I think it is linked - I would add that if you leave a directory with an .fnmrc the node version should switch back to system (assuming there isn't an .fnmrc in the new dir)

@jorgebucaran
Copy link
Owner

@jwhitmarsh It should be possible using your own node wrapper function.

See also:

@yegorius
Copy link

I have created a fork where you can revert to system node and which doesn't set node version globally. Basically, it doesn't use $fish_user_paths universal variable and only changes $PATH which only affects current fish session. Also, nvm unuse will reset the $PATH to its initial state.
https://github.com/yegorius/fish-nvm

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or fix
Projects
None yet
Development

No branches or pull requests

5 participants