HomeFreeBSD

shellcheck: disable "unreachable command" check [SC2317]

Description

shellcheck: disable "unreachable command" check [SC2317]

This new check in 0.9.0 appears to have some issues with various forms
of "early return", like trap, exit and return. This is tripping up (at
least):

  cmd/zed/zed.d/history_event-zfs-list-cacher.sh
  /etc/zfs/zfs-functions

Its not obvious what its complaining about or what the remedy is, so it
seems sensible to disable this check for now.

See also:

  https://www.shellcheck.net/wiki/SC2317
  https://github.com/koalaman/shellcheck/issues/2542
  https://github.com/koalaman/shellcheck/issues/2613

Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov>
Signed-off-by: Rob Norris <robn@despairlabs.com>
Closes #15089

Details

Provenance
rob.norris_klarasystems.comAuthored on Jul 21 2023, 6:53 PM
GitHub <noreply@github.com>Committed on Jul 21 2023, 6:53 PM
Parents
rG46adb2820ac3: metaslab: tuneable to better control force ganging
Branches
Unknown
Tags
Unknown