Commit 7a9db6cf authored by Nathan Rajlich's avatar Nathan Rajlich
Browse files

install: add a "portable" mode to the shebang-rewriting logic

This "portable" mode rewrites the npm shebang to use the "node" executable
in the same directory relative to the "npm" script. This makes the "npm"
script "just work" even when "node" is not in the user's $PATH.

This mode is necessary for the precompiled binary packages that may potentially
be extracted to anywhere. The regular shebang-rewriting logic would normally
set the npm script's shebang to "/bin/node" which will not be present on anyone's
machine. In the end, we want the precompiled packages to be as user-friendly as
possible.
parent 6bdd4d02
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment