File tree 1 file changed +6
-2
lines changed
1 file changed +6
-2
lines changed Original file line number Diff line number Diff line change @@ -139,7 +139,7 @@ if ((SHELLCHECK_DISABLE != 1)); then
139
139
$shellcheck_output
140
140
----------
141
141
142
- You can address the above issues in on of three ways:
142
+ You can address the above issues in one of three ways:
143
143
1. Manually correct the issue in the offending shell script;
144
144
2. Disable specific issues by adding the comment:
145
145
# shellcheck disable=NNNN
155
155
if (( SHFMT_DISABLE != 1 )) ; then
156
156
printf " Validating %d shell script(s) using 'shfmt %s':\\ n" " ${# sh_files[@]} " " $SHFMT_OPTS "
157
157
IFS=$' \t\n ' read -d ' ' -ra args <<< " $SHFMT_OPTS"
158
+ # Error with a diff when the formatting differs
159
+ args+=(' -d' )
160
+ # Disable colorization of diff output
161
+ export NO_COLOR=1
158
162
shfmt_output=" $( shfmt " ${args[@]} " " ${sh_files[@]} " 2>&1 ) "
159
163
shfmt_code=$?
160
164
if (( shfmt_code == 0 )) ; then
@@ -189,7 +193,7 @@ if ((CHECKBASHISMS_ENABLE == 1)); then
189
193
printf ' \ncheckbashisms returned error %d finding the bashisms listed above.\n' " $checkbashisms_code "
190
194
if (( checkbashisms_code == 4 )) ; then
191
195
# see https://github.com/duggan/shlint/blob/0fcd979319e3f37c2cd53ccea0b51e16fda710a1/lib/checkbashisms#L489
192
- printf " \\ nIgnoring 'could not find any possible bashisms in bash script' issues \\ n"
196
+ printf " \\ nIgnoring the spurious non-issue titled 'could not find any possible bashisms in bash script'\\ n"
193
197
else
194
198
# checkbashisms returns 0-3: https://linux.die.net/man/1/checkbashisms
195
199
(( exit_code |= (checkbashisms_code << 4 )) )
You can’t perform that action at this time.
0 commit comments