tools/shellcheck.sh: allow overriding the shellcheck path
authorSimon Marchi <simon.marchi@efficios.com>
Mon, 29 Jan 2024 21:54:10 +0000 (16:54 -0500)
committerSimon Marchi <simon.marchi@efficios.com>
Wed, 7 Feb 2024 21:12:33 +0000 (16:12 -0500)
commitb939afe57d2f5911460fab65e334b789d2a96bd5
tree705da6b14853dc93eaf08ae32b40a61b6e99620a
parent10ba5f69235e1dc943a716ecf6db3ee62463e066
tools/shellcheck.sh: allow overriding the shellcheck path

For an unknown (to me) reason, the shellcheck binary from the Arch Linux
package (version 0.9.0-79) hits this error:

    $ tools/shellcheck.sh
    ...
    Running ShellCheck on `./tests/cli/test-intersection.sh`
    shellcheck: (Array.!): undefined array element
    ...

This looks like an error internal to shellcheck.  When using the Linux
x86-64 binary from the release [1], it works fine.  Add a way to
override the shellcheck binary in shellcheck.sh, to make working around
this easier:

    $ SHELLCHECK=/home/smarchi/Downloads/shellcheck-v0.9.0/shellcheck tools/shellcheck.sh
    ... all fine !

[1] https://github.com/koalaman/shellcheck/releases/tag/v0.9.0

Change-Id: I81f0ea2e40b9dbac75e0b0debcce63338986358c
Signed-off-by: Simon Marchi <simon.marchi@efficios.com>
Reviewed-on: https://review.lttng.org/c/babeltrace/+/11755
Tested-by: jenkins <jenkins@lttng.org>
Reviewed-by: Philippe Proulx <eeppeliteloop@gmail.com>
tools/shellcheck.sh
This page took 0.026355 seconds and 4 git commands to generate.