News for hackers. Stuff that matters.
Re:Understanding the bin, sbin, usr/bin, usr/sbin split (2010) by kyuudou on Wednesday March 18, 2020 @12:57PM (#22618727)
There's some debate about this if I recall correctly from the last deep dive I did about the pros and cons of it.

If I am writing a script that needs to be that portable, then I'll use #!/usr/bin/env sh but otherwise /bin/sh will work in all the cases I need it to.

Since bash's path might vary more, I might consider calling env to locate it then more often.

Re:Understanding the bin, sbin, usr/bin, usr/sbin split (2010) by naniwaduni on Wednesday March 18, 2020 @03:12PM (#22620173)
If you're writing a script that needs to be that portable, you're doomed anyway and you might even find the autoconf manual's "Limitations of Shell Builtins" section useful.
Re:Understanding the bin, sbin, usr/bin, usr/sbin split (2010) by oat_bravo_nap on Wednesday March 18, 2020 @04:21PM (#22620840)
If you are using /bin/sh you need to check sure it is a POSIX shell script and not using bash features [1]. On Debian and derivatives /bin/sh is ash not bash.

[1] https://linux.die.net/man/1/checkbashisms