not only does the shebang point to bash, it is also full of bashisms:
$ checkbashisms usage.sh
possible bashism in usage.sh line 2 ('function' is useless):
function usage() {
possible bashism in usage.sh line 9 ('function' is useless):
function platform() {
possible bashism in usage.sh line 13 ('function' is useless):
function require() {
possible bashism in usage.sh line 17 ('function' is useless):
function options() {
possible bashism in usage.sh line 25 ('function' is useless):
function option() {
not only is "'function' is useless", but it is obviously harmful on some systems.
E.g. here i get a syntax error:
(i'm running this on linux, and faust2au obviously won't produce any meaningful results later on, but i don't think this is a valid reason to not fix the issue at hand).
the simple fix is to just change the shebang of faust2au to bash:
#!/usr/bin/env bash
the (imho) better fix is to remove the bashisms from the common script snippets.
faust2au
declares to be a POSIX shell script https://github.com/grame-cncm/faust/blob/91aa53805b51d4f11feb8030b21bd6baca98e81b/tools/faust2appls/faust2au#L1however, it includes
usage.sh
, which is a bash script https://github.com/grame-cncm/faust/blob/91aa53805b51d4f11feb8030b21bd6baca98e81b/tools/faust2appls/usage.sh#L1not only does the shebang point to bash, it is also full of bashisms:
not only is "'function' is useless", but it is obviously harmful on some systems. E.g. here i get a syntax error:
(i'm running this on linux, and
faust2au
obviously won't produce any meaningful results later on, but i don't think this is a valid reason to not fix the issue at hand).the simple fix is to just change the shebang of
faust2au
to bash:the (imho) better fix is to remove the bashisms from the common script snippets.