node.js - /usr/bin/env node Shebang does not work on Mac OSX in certain cases -
i have simple node script acts native host chrome extension. when shebang on node script is
#! /usr/local/bin/node
the script runs fine. i.e. chrome extension able connect native host. when change shebang
#! /usr/bin/env node
the chrome extension unable connect native host.
when execute script terminal
./index.js
it executes in both cases.
but when chrome extension tries execute it, fails in second case.
since developing extension, not downloaded internet have quarantine xattr assigned it.
i have asked similar problem facing when trying detect whether node installed on system when installing package. there if full path of node not given script fails.
why script works in terminal not work when chrome extension tries execute it?
Comments
Post a Comment