-
Notifications
You must be signed in to change notification settings - Fork 144
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 postinstall hooks not run with npm 5.3.0 #47
Comments
Same problem with npm 5.1.0 and 5.2.0: ▲ ~ npm i -g coffeescript
/Users/noir/.asdf/installs/nodejs/8.1.2/.npm/bin/coffee -> /Users/noir/.asdf/installs/nodejs/8.1.2/.npm/lib/node_modules/coffeescript/bin/coffee
/Users/noir/.asdf/installs/nodejs/8.1.2/.npm/bin/cake -> /Users/noir/.asdf/installs/nodejs/8.1.2/.npm/lib/node_modules/coffeescript/bin/cake
+ [email protected]
updated 1 package in 1.352s
▲ ~ coffee
zsh: command not found: coffee But with 5.0.4 everything is ok |
For now you can fix this by manually shimming: |
I had this issue and I wasn't entirely sure how to use @caleb 's fix. Based on what he provided I came up with the following:
It didn't work after the first command, but it did after the second. I'm not entirely sure the first command was necessary, so ymmv. |
Yeah, same problem on macos. This is pretty annoying, any idea how we can fix this? |
I think the shims work in the newest version of this plugin... It doesn't use a post install hook anymore, so try upgrading to the newest version of the plugin: This seems to have worked for me. |
I just upgraded the plugin to the newest version, but I still need to execute |
@zainfathoni You are right, the automatic shimming is broken for me too. edit: Try re-installing your nodejs... maybe you installed at a time when the npm postinstall hook wasn't installed on installation of a new node version... It /seems/ to work for me when I wiped my nodejs versions and did a new |
Thanks for the suggestion @caleb, I will try it out later. 😄 |
Hi @caleb , I already installed a new version of nodejs and tried to install
Is it necessary to reinstall the |
You just have to make sure your NodeJS asdf plug in is the latest version before installing NodeJS.
It has been working for me. So maybe your asdf plug in is not up to date
…Sent from my iPhone
On Oct 21, 2017, at 10:06 AM, Zain Fathoni ***@***.***> wrote:
Hi @caleb , I already installed a new version of nodejs and tried to install vue-cli globally, but it still didn't shimmed correctly. So I still had to execute asdf reshim nodejs 8.7.0 again to make vue command available globally.
$ asdf install nodejs 8.7.0
$ asdf global nodejs 8.7.0
$ npm install -g vue-cli
Is it necessary to reinstall the asdf-nodejs plugin to make it works?
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub, or mute the thread.
|
I'm needing to manually re-shim after globally installing libraries too. I just set up asdf and asdf-nodejs today, and still seeing the behaviour. |
It still happens ➜ ~ node -v
v15.0.1
➜ ~ npm -v
7.0.3
➜ ~ which node
/Users/Will/.asdf/shims/node
➜ ~ which npm
/Users/Will/.asdf/shims/npm
➜ ~ npm i -g pnpm
added 1 package, and audited 1 package in 8s
➜ ~ pnpm
fish: Unknown command: pnpm
➜ ~ asdf reshim nodejs
➜ ~ pnpm -v
5.10.2
➜ ~ which pnpm
/Users/Will/.asdf/shims/pnpm |
As @willbchang said, it still happening for me too :( |
This issue is solved on master now. The problem was on the npm side, it didn't fully support npm |
As tested on two Ubuntu boxes and a Mac:
The text was updated successfully, but these errors were encountered: