GH Actions: add shellcheck job + allow scripts to pass the new check #924
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Detailed Description
GH Actions: add shellcheck job
Shellcheck is a static analysis tool for shell scripts, which can help find common mistakes, simplifications and point out best practices.
This commit adds a new GH Actions job to run shellcheck on all shell scripts in this repo.
At this moment, that means it will run over the
tests/utils/proxy
start/stop scripts, but more scripts are expected to be added in the near future.I've researched the available action runners and found the
ludeeus/action-shellcheck
one to be the most popular as well as suitable for our needs.Additionally, the
lumaxis/shellcheck-problem-matchers
will allow for showing any issues found inline in the GH code view via annotations.Refs:
[INCOMPLETE] Shell scripts: various tweaks
Various tweaks to allow the scripts to pass the shellcheck checks.
shellcheck
- this is mostly due to quoting$ARGS
in thestart-stop-daemon
command breaking the test runs. For that reason, this PR is being opened as draft.