Silence 'make checkbashisms'
authorBrian Behlendorf <behlendorf1@llnl.gov>
Thu, 20 Aug 2020 20:45:47 +0000 (13:45 -0700)
committerGitHub <noreply@github.com>
Thu, 20 Aug 2020 20:45:47 +0000 (13:45 -0700)
commit64025fa3a1f0f710f7f8678f2ac459b07ed9f88f
tree740ffc937bb1c9e4964054ad619f464cc060fe0c
parent7bba1d404cd213223cfca017035f9ebf8683a8ef
Silence 'make checkbashisms'

Commit d2bce6d03 added the 'make checkbashisms' target but did not
resolve all of the bashisms in the scripts.  This commit doesn't
resolve them all either but it does fix up a few, and it excludes
the others so 'make checkstyle' no longer prints warnings.  It's
a small step in the right direction.

* Dracut is Linux specific and itself depends on bash.  Therefore
  all dracut support scripts can be bash specific, update their
  shebang accordingly.

* zed-functions.sh, zfs-import, zfs-mount, zfs-zed, smart
  paxcheck.sh, make_gitrev.sh - these scripts were excuded from
  the check until they can be updated and properly tested.

* zfsunlock - only whole values for sleep are allowed.

* vdev_id - removed unneeded locals; use && instead of -a.

* dkms.mkconf, dkms.postbuil - use || instead of -o.

Reviewed-by: InsanePrawn <insane.prawny@gmail.com>
Reviewed-by: Gabriel A. Devenyi <gdevenyi@gmail.com>
Reviewed-by: Ryan Moeller <ryan@iXsystems.com>
Reviewed-by: George Melikov <mail@gmelikov.ru>
Signed-off-by: Brian Behlendorf <behlendorf1@llnl.gov>
Closes #10755
Makefile.am
cmd/vdev_id/vdev_id
contrib/dracut/90zfs/export-zfs.sh.in
contrib/dracut/90zfs/mount-zfs.sh.in
contrib/dracut/90zfs/parse-zfs.sh.in
contrib/dracut/90zfs/zfs-lib.sh.in
contrib/dracut/90zfs/zfs-load-key.sh.in
contrib/dracut/90zfs/zfs-needshutdown.sh.in
contrib/initramfs/zfsunlock
scripts/dkms.mkconf
scripts/dkms.postbuild