Open t18n opened 2 years ago
The simplest thing you can do is simply update your shebang to the full path of your python installation, i.e.:
#!/usr/local/bin/env /Users/me/.asdf/shims/python
However, I wanted this to work "portably" across my various computers, which had node (in my case) in different places. asdf
-controlled on one, and brew
-controlled on another. So, based partly on the advice given in #730 I investigated the env
commandline args, and found that -S
and -P
can work together to "augment" the path for the purposes of the execution. Thus I ended up with:
!/usr/bin/env -S-P/Users/me/.asdf/shims:/usr/local/bin:/usr/bin:${PATH} node
That way asdf
node will be found first, if it exists, then /usr/local/bin
if it exists, and so on, and we even have whatever PATH xbar plugins get at the end, so we don't clobber that. This works for me.
I installed Xbar and github-review-requests but the plugin says "env: python: No such file or directory".
Since I installed python with asdf, the execution path is
/Users/me/.asdf/shims/python
. I tried to symlink it tousr/bin/python
but it doesn't work since MacOS blocks it. I then symlink it tousr/local/bin/python
, and changed the plugin header fromto
but it still doesn't work. Did I miss something?
On an extra node, running
on the terminal works.