Giter VIP home page Giter VIP logo

Comments (4)

Stratus3D avatar Stratus3D commented on June 18, 2024 1

To @HashNuke and other asdf folks: might I suggest falling back to $HOME/.tool-versions in the event that no .tool-versions is found? There are some npm packages that like to build in /tmp.

This should be the case with the recent versions of asdf. I am going to close this issue. Please open a new issue if this problem isn't fully resolved.

from asdf-nodejs.

rstacruz avatar rstacruz commented on June 18, 2024

npm WARN lifecycle The node binary used for scripts is /Users/jason/.asdf/shims/node but npm is using /Users/jason/.asdf/installs/nodejs/8.10.0/bin/node itself. Use the --scripts-prepend-node-path option to include the path for the node binary npm was executed with.

This issue should not be a big deal.

from asdf-nodejs.

rstacruz avatar rstacruz commented on June 18, 2024

No version set for nodejs

  1. Can you try asdf global nodejs 8.10.0 then try again?
  2. Okay, so that probably won't work. Can you try cd /tmp; asdf local nodejs 8.10.0 and then install it again?

If 2 works, then it's probably because serverless is building in /tmp, and asdf doesn't have a version of nodejs available for that path.

To @HashNuke and other asdf folks: might I suggest falling back to $HOME/.tool-versions in the event that no .tool-versions is found? There are some npm packages that like to build in /tmp.

from asdf-nodejs.

axelson avatar axelson commented on June 18, 2024

1 worked for me, thanks!

Jasons-MBP-2% npm install -g serverless
/Users/jason/.asdf/installs/nodejs/8.10.0/.npm/bin/slss -> /Users/jason/.asdf/installs/nodejs/8.10.0/.npm/lib/node_modules/serverless/bin/serverless
/Users/jason/.asdf/installs/nodejs/8.10.0/.npm/bin/serverless -> /Users/jason/.asdf/installs/nodejs/8.10.0/.npm/lib/node_modules/serverless/bin/serverless
/Users/jason/.asdf/installs/nodejs/8.10.0/.npm/bin/sls -> /Users/jason/.asdf/installs/nodejs/8.10.0/.npm/lib/node_modules/serverless/bin/serverless
npm WARN lifecycle The node binary used for scripts is /Users/jason/.asdf/shims/node but npm is using /Users/jason/.asdf/installs/nodejs/8.10.0/bin/node itself. Use the `--scripts-prepend-node-path` option to include the path for the node binary npm was executed with.

> [email protected] postinstall /Users/jason/.asdf/installs/nodejs/8.10.0/.npm/lib/node_modules/serverless/node_modules/spawn-sync
> node postinstall


> [email protected] postinstall /Users/jason/.asdf/installs/nodejs/8.10.0/.npm/lib/node_modules/serverless/node_modules/spawn-sync
> /Users/jason/.asdf/installs/nodejs/8.10.0/.npm/lib/node_modules/.hooks/postinstall

> [email protected] postinstall /Users/jason/.asdf/installs/nodejs/8.10.0/.npm/lib/node_modules/serverless
> node ./scripts/postinstall.js


[tabtab] Adding source line to load /Users/jason/.asdf/installs/nodejs/8.10.0/.npm/lib/node_modules/serverless/node_modules/tabtab/.completions/serverless.zsh
in /Users/jason/.zshrc


[tabtab] Adding source line to load /Users/jason/.asdf/installs/nodejs/8.10.0/.npm/lib/node_modules/serverless/node_modules/tabtab/.completions/sls.zsh
in /Users/jason/.zshrc


> [email protected] postinstall /Users/jason/.asdf/installs/nodejs/8.10.0/.npm/lib/node_modules/serverless
> /Users/jason/.asdf/installs/nodejs/8.10.0/.npm/lib/node_modules/.hooks/postinstall
+ [email protected]
added 310 packages in 18.453s

To @HashNuke and other asdf folks: might I suggest falling back to $HOME/.tool-versions in the event that no .tool-versions is found? There are some npm packages that like to build in /tmp.

That sounds like a good idea to me. Also maybe setting a global version should be recommended more heavily, although if you have 2 different npm versions installed and you want to install a package globally it is annoying to have to switch your asdf global to match asdf current.

from asdf-nodejs.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.