running sh scripts through shellcheck

Rowland Penny rpenny at samba.org
Fri Aug 11 08:20:33 UTC 2017


OK, I have got to ctdb/tests/complex/30_nfs_tickle_killtcp.sh where I
have found this:

echo "Getting MAC address associated with ${test_ip}..."
releasing_mac=$(ip neigh show "$test_prefix" | awk '$4 == "lladdr" {print $5}')
[ -n "$releasing_mac" ] || die "Couldn't get MAC address for ${test_prefix}"
echo "MAC address is: ${releasing_mac}"

So, who doesn't know that 'die' is a perl thing ?

There doesn't seem to be a 'die' function.

The script is also a 'bash' script instead of a 'sh' script.

Rowland



More information about the samba-technical mailing list