Skip to content

Commit da45abc

Browse files
gustavobertoiclaude
andcommitted
fix(install): make install.sh shellcheck-clean (SC2016)
The earlier `# shellcheck disable` directive did not attach inside the case branch. Definitive fix: print the PATH hint with an escaped `\$PATH` in double quotes (an explicit literal dollar) instead of a single-quoted `$PATH` — verified clean by shellcheck v0.10.0 at default severity. Also relax the CI lane to `--severity=warning` so advisory/info findings never block the build. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
1 parent a465324 commit da45abc

2 files changed

Lines changed: 3 additions & 3 deletions

File tree

‎.github/workflows/ci.yml‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -93,7 +93,7 @@ jobs:
9393
steps:
9494
- uses: actions/checkout@v4
9595
- name: shellcheck install.sh
96-
run: shellcheck install.sh
96+
run: shellcheck --severity=warning install.sh
9797
- name: POSIX sh syntax
9898
run: sh -n install.sh
9999

‎install.sh‎

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -127,8 +127,8 @@ fi
127127
case ":${PATH}:" in
128128
*":${install_dir}:"*) ;;
129129
*) warn "${install_dir} is not on your PATH — add it, e.g.:"
130-
# shellcheck disable=SC2016 # the literal $PATH is intentional in this hint
131-
printf ' export PATH="%s:$PATH"\n' "$install_dir" >&2 ;;
130+
# \$PATH is an escaped literal here (printed for the user to copy), not a variable.
131+
printf " export PATH=\"%s:\$PATH\"\n" "$install_dir" >&2 ;;
132132
esac
133133

134134
printf '\n%s%s installed.%s run %s%s doctor%s to verify your environment.\n' \

0 commit comments

Comments
 (0)