From 0e3268fe23b7d2b48aeabd5b11911eb5d3edbd5d Mon Sep 17 00:00:00 2001 From: Remi Antczak <140408771+remigiusz-antczak@users.noreply.github.com> Date: Fri, 13 Nov 2026 05:06:03 +0100 Subject: [PATCH] Fix comment parsed as a shellcheck directive in test-provision-tools.sh A comment starting with '# shellcheck, ruff and ...' is parsed by shellcheck as a directive (SC1073/SC1072), so shellcheck stopped checking the file. Reword to '# The shellcheck, ruff and ...'. No other tracked *.sh file has a non-directive '# shellcheck' comment. shellcheck -S warning now reports no findings on the file. Tests: 61/61 Co-Authored-By: Claude Sonnet 5.5 --- scripts/test-provision-tools.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/scripts/test-provision-tools.sh b/scripts/test-provision-tools.sh index cc6726349..344e85d09 100644 --- a/scripts/test-provision-tools.sh +++ b/scripts/test-provision-tools.sh @@ -174,7 +174,7 @@ e "review_checks: partial: semgrep ran but reported errors" && e "review_checks: rc_run SG_ERR='{"message":"boom"}' # errors and no findings: nothing usable was scanned e "not run: semgrep (scan errored, no findings)" && st '.not_run == ["semgrep"] and .partial == []' && ok "semgrep with errors and no findings: not run, not partial" || { bad "errored semgrep"; cat "$T/err"; } -# shellcheck, ruff and the history scan count as wired, but provision_tools.sh cannot install them: not run, never fixable +# The shellcheck, ruff and the history scan count as wired, but provision_tools.sh cannot install them: not run, never fixable mkrepo repo3; echo 'echo hi' >t.sh; echo 'x = 1' >t.py; commit SX=$(mktemp -d "$T/sx.XXXXXX"); printf '#!/bin/sh\nexit "${LINT_RC:-0}"\n' >"$SX/shellcheck"; printf '#!/bin/sh\ncase "$*" in *json*) echo "[]" ;; esac\nexit "${LINT_RC:-0}"\n' >"$SX/ruff" # ruff also backs the ruff-security hub row (JSON) printf '#!/bin/sh\necho %s\n' "'{\"results\":[]}'" >"$SX/bandit"; chmod +x "$SX"/* # bandit: the hub tool a .py file wires