argbash icon indicating copy to clipboard operation
argbash copied to clipboard

Hardcoded bash path?

Open julian-hoch opened this issue 3 years ago • 3 comments

This is just a quesiton - is there a reason why the bash code is hardcoded to /bin/bash? Since I run NixOS I always have to manually change it o /usr/bin/env bash, since /bin/bash does not exist. But perhaps I am missing something?

julian-hoch avatar Dec 02 '23 11:12 julian-hoch

POSIX standard requires env to be present, so switching to using it for all shebangs is a reasonable change

gdevenyi avatar Dec 02 '23 14:12 gdevenyi

Agreed. MacOS ships with a very old bash and so anyone on that platform that scripts with bash will invariably use the bash installed via Homebrew in /opt/homebrew/bin. I globally replaced all instances of #!/bin/bash with #!/usr/bin/env bash and ran make and everything worked just fine. Seems like an easy win if it also works for other OS's.

kirtfitzpatrick avatar Oct 20 '24 00:10 kirtfitzpatrick

Fixed by #187. There is no /bin/bash in the source.

matejak avatar May 11 '25 08:05 matejak