Skip to content

Commit 6b1dc19

Browse files
committed
Get and use latest shellcheck for tests
Now we use shellcheck 0.7.0 on Ubuntu hosts for test, but also use 0.7.2 or later on macOS host via brew. So, not specifying version and always fetch & run latest version of shellcheck on Ubuntu host is better. We don't have a reason to stick to 0.7.0, IMHO.
1 parent 3204014 commit 6b1dc19

File tree

2 files changed

+6
-6
lines changed

2 files changed

+6
-6
lines changed

.github/workflows/main.yml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -14,9 +14,9 @@ jobs:
1414
run: |
1515
sudo apt-get update -y
1616
sudo apt-get install -y devscripts debhelper moreutils fakeroot jq pigz
17-
wget "https://github.com/koalaman/shellcheck/releases/download/v0.7.0/shellcheck-v0.7.0.linux.x86_64.tar.xz"
18-
tar --xz -xvf "shellcheck-v0.7.0.linux.x86_64.tar.xz"
19-
sudo cp shellcheck-v0.7.0/shellcheck /usr/bin/shellcheck
17+
wget "https://github.com/koalaman/shellcheck/releases/download/latest/shellcheck-latest.linux.x86_64.tar.xz"
18+
tar --xz -xvf "shellcheck-latest.linux.x86_64.tar.xz"
19+
sudo cp shellcheck-latest/shellcheck /usr/bin/shellcheck
2020
if: matrix.os != 'macos-latest'
2121
- name: Install Dependencies (macOS)
2222
run: |

test/test-shellcheck.sh

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -9,10 +9,10 @@ BASE_PATH=$(cd "$(dirname "$0")/../" && pwd)
99
begin_test "shellcheck: reports no errors or warnings"
1010
(
1111
set -e
12-
# We manually install Shellcheck 0.7.0 on Linux builds as other options
12+
# We manually install the latest Shellcheck on Linux builds as other options
1313
# are too old.
14-
if [ -x "$BASE_PATH/shellcheck-v0.7.0/shellcheck" ]; then
15-
shellcheck() { "$BASE_PATH/shellcheck-v0.7.0/shellcheck" "$@"; }
14+
if [ -x "$BASE_PATH/shellcheck-latest/shellcheck" ]; then
15+
shellcheck() { "$BASE_PATH/shellcheck-latest/shellcheck" "$@"; }
1616
fi
1717

1818
if ! type shellcheck 1>/dev/null 2>&1; then

0 commit comments

Comments
 (0)