Files
Jan MackuandLuca Di Maio 4027617a55 CI: add another Shell linter - Differential-ShellCheck (#372)
* ci(lint): Add differential-shellcheck action

It performs differential ShellCheck scans and report results directly in
pull request.

documentation: https://github.com/redhat-plumbers-in-action/differential-shellcheck

Signed-off-by: Jan Macku <jamacku@redhat.com>
Signed-off-by: Luca Di Maio <luca.dimaio1@gmail.com>
Co-authored-by: Luca Di Maio <luca.dimaio1@gmail.com>
2022-09-01 18:22:06 +02:00

21 lines
1.0 KiB
Plaintext

# Overrides the shell detected from the shebang. This is useful for files meant to be included (and thus lacking a shebang), or possibly as a more targeted alternative to 'disable=SC2039'.
shell=sh
# Always allow ShellCheck to open arbitrary files from 'source' statements.
external-sources=true
# Enable all optional checks
enable=all
# This function is invoked in an 'if' condition so set -e will be disabled. Invoke separately if failures should cause the script to exit.
# - We don't want to exit if errors happen inside a check, that's why we have a check...
disable=SC2310
# Bash implicitly disabled set -e for this function invocation because it's inside a command substitution. Add set -e; before it or enable inherit_errexit.
# - Don't care if we inherit errexit inside substitutions, we do checks for that.
disable=SC2311
# Consider invoking this command separately to avoid masking its return value (or use '|| true' to ignore).
# - We already check errors and adding "|| true" everywhere hinders readability.
disable=SC2312