From: James Clark <james.clark@linaro.org>
To: Peter Zijlstra <peterz@infradead.org>,
Ingo Molnar <mingo@redhat.com>,
Arnaldo Carvalho de Melo <acme@kernel.org>,
Namhyung Kim <namhyung@kernel.org>,
Mark Rutland <mark.rutland@arm.com>,
Alexander Shishkin <alexander.shishkin@linux.intel.com>,
Jiri Olsa <jolsa@kernel.org>, Ian Rogers <irogers@google.com>,
Adrian Hunter <adrian.hunter@intel.com>
Cc: linux-perf-users@vger.kernel.org, linux-kernel@vger.kernel.org,
James Clark <james.clark@linaro.org>
Subject: [PATCH 0/2] perf test: Improve shellcheck source directives
Date: Mon, 21 Sep 2026 16:47:27 +0100 [thread overview]
Message-ID: <20260921-james-perf-shellcheck-source-v1-0-adcfc107c997@linaro.org> (raw)
I was hacking away when I got blocked by a shellcheck warning about an
unassigned variable, despite that variable being assigned in a sourced
file and having visibly correct source= directive.
Confusingly two things turned out to be relevant to this. One is that -a
doesn't make shellcheck follow "external" paths, which these are treated
as. You need -x for that. Secondly, the source= directives don't cause
it to follow the path either, they just suppress a warning message about
dynamic paths in versions of shellcheck before 0.7.2. This warning can
be silenced with "source=/dev/null" and doesn't require any particular
path to be provided if -x isn't used.
Signed-off-by: James Clark <james.clark@linaro.org>
---
James Clark (2):
perf test: Remove redundant shellcheck source paths
perf build: Follow sourced files when running shellcheck
tools/perf/Makefile.perf | 2 +-
tools/perf/tests/shell/annotate.sh | 1 -
tools/perf/tests/shell/base_probe/test_adding_kernel.sh | 1 -
tools/perf/tests/shell/diff.sh | 1 -
tools/perf/tests/shell/inject_aslr.sh | 1 -
tools/perf/tests/shell/jitdump-python.sh | 1 -
tools/perf/tests/shell/list.sh | 1 -
tools/perf/tests/shell/pipe_test.sh | 1 -
tools/perf/tests/shell/probe_vfs_getname.sh | 2 --
tools/perf/tests/shell/python-use.sh | 1 -
tools/perf/tests/shell/record+probe_libc_inet_pton.sh | 2 --
tools/perf/tests/shell/record+script_probe_vfs_getname.sh | 2 --
tools/perf/tests/shell/record.sh | 2 --
tools/perf/tests/shell/record_weak_term.sh | 1 -
tools/perf/tests/shell/script_dlfilter.sh | 1 -
tools/perf/tests/shell/stat+csv_output.sh | 1 -
tools/perf/tests/shell/stat+json_output.sh | 1 -
tools/perf/tests/shell/stat+std_output.sh | 1 -
tools/perf/tests/shell/stat_metrics_values.sh | 1 -
tools/perf/tests/shell/test_arm_callgraph_fp.sh | 1 -
tools/perf/tests/shell/test_brstack.sh | 1 -
tools/perf/tests/shell/test_data_symbol.sh | 1 -
tools/perf/tests/shell/test_intel_pt.sh | 1 -
tools/perf/tests/shell/test_perf_data_converter_json.sh | 1 -
tools/perf/tests/shell/test_test_junit_output.sh | 1 -
tools/perf/tests/shell/test_uprobe_from_different_cu.sh | 1 -
tools/perf/tests/shell/trace+probe_vfs_getname.sh | 1 -
tools/perf/tests/shell/trace_btf_enum.sh | 1 -
tools/perf/tests/shell/trace_btf_general.sh | 1 -
tools/perf/tests/shell/trace_exit_race.sh | 1 -
tools/perf/tests/shell/trace_record_replay.sh | 2 --
tools/perf/tests/shell/trace_summary.sh | 1 -
32 files changed, 1 insertion(+), 37 deletions(-)
---
base-commit: 9453bc6a69ef43755f1c28d5688cacdd69fa16bd
change-id: 20260921-james-perf-shellcheck-source-f48df891cd4f
Best regards,
--
James Clark <james.clark@linaro.org>
next reply other threads:[~2026-09-21 15:47 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-09-21 15:47 James Clark [this message]
2026-09-21 15:47 ` [PATCH 1/2] perf test: Remove redundant shellcheck source paths James Clark
2026-09-21 15:47 ` [PATCH 2/2] perf build: Follow sourced files when running shellcheck James Clark
2026-09-21 20:46 ` [PATCH 0/2] perf test: Improve shellcheck source directives Namhyung Kim
2026-09-24 17:50 ` Arnaldo Carvalho de Melo
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20260921-james-perf-shellcheck-source-v1-0-adcfc107c997@linaro.org \
--to=james.clark@linaro.org \
--cc=acme@kernel.org \
--cc=adrian.hunter@intel.com \
--cc=alexander.shishkin@linux.intel.com \
--cc=irogers@google.com \
--cc=jolsa@kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-perf-users@vger.kernel.org \
--cc=mark.rutland@arm.com \
--cc=mingo@redhat.com \
--cc=namhyung@kernel.org \
--cc=peterz@infradead.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®