Re:Use long flags when scripting
by wollw on Tuesday February 05, 2013 @01:07AM
(#5169426)
It's probably safer to use:
Assuming env is installed (I believe I had to install a package on OpenBSD to use it) this will find the first instance of bash in the PATH.
[ Parent
| on HN ]
How do you know env is in /usr/bin rather than in /bin or /usr/local/bin? I'm just curious...
You don't, but I've run into more problems with bash being in unexpected places than env.
Right on, thanks.