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

npm' packages installed to global that couldn't find them. #3

Closed
IvanWei opened this Issue Jun 12, 2016 · 3 comments

Comments

Projects
None yet
2 participants
@IvanWei
Copy link

IvanWei commented Jun 12, 2016

bower installed to global, fish known bower. When I restart fish that didn't know bower.

@ghost

This comment has been minimized.

Copy link

ghost commented Jun 12, 2016

@IvanWei Hi! I can't help you with this plugin so you'll need to talk to @FabioAntunes :)

In the meantime, check out fnm or verman which I maintain and are known to work with global modules.

@FabioAntunes

This comment has been minimized.

Copy link
Owner

FabioAntunes commented Jun 13, 2016

@IvanWei nvm isn't being sourced on shell init, so unless you run nvm or npm first on your terminal, bower won't be recognized.

You could create a bower.fish in your functions folder inside ~/.config/fish and then paste this:

function bower -d "Package manager"
__nvm_run "bower" $argv
end

But as @BRJ said, try fnm or verman they are pure fish version managers

@IvanWei

This comment has been minimized.

Copy link
Author

IvanWei commented Jun 14, 2016

@FabioAntunes Thank you! 😄

I know this idea, but it isn't convenient.
if many packages installed to global that need create more fish files.

@FabioAntunes

This comment has been minimized.

Copy link
Owner

FabioAntunes commented Jun 14, 2016

@IvanWei If you really want to be able to run global packages you can source nvm on shell init, but be prepared to see a delay of some seconds. You can read more about that in this issue #2

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment