0

When trying to install npm on "bash on ubuntu on windows", it installs, but every call to npm or whatever results in the error:

"/usr/bin/env: node: No such file or directory"

How to solve this?

1 Answer 1

1

This is often a misnaming error, if you install from a package manager you bin may be called nodejs so you just need to symlink it.

In "bash on ubuntu on windows", one has to run it with sudo:

sudo ln -s /usr/bin/nodejs /usr/bin/node

Originally found here: https://github.com/nodejs/node-v0.x-archive/issues/3911
(Thanks, digitalmediums)

Sign up to request clarification or add additional context in comments.

1 Comment

There may be similiar answers around, i posted it here again to have fitting tags for the specific "bash on ubuntu on windows" solution.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.