Skip to content

Commit 83c48d9

Browse files
committed
fix locale for lint-shell
1 parent 990e182 commit 83c48d9

File tree

1 file changed

+9
-3
lines changed

1 file changed

+9
-3
lines changed

test/lint/lint-shell.sh

Lines changed: 9 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -6,9 +6,15 @@
66
#
77
# Check for shellcheck warnings in shell scripts.
88

9-
# This script is intentionally locale dependent by not setting "export LC_ALL=C"
10-
# to allow running certain versions of shellcheck that core dump when LC_ALL=C
11-
# is set.
9+
export LC_ALL=C
10+
11+
# The shellcheck binary segfault/coredumps in Travis with LC_ALL=C
12+
# It does not do so in Ubuntu 14.04, 16.04, 18.04 in versions 0.3.3, 0.3.7, 0.4.6
13+
# respectively. So export LC_ALL=C is set as required by lint-shell-locale.sh
14+
# but unset here in case of running in Travis.
15+
if [ "$TRAVIS" = "true" ]; then
16+
unset LC_ALL
17+
fi
1218

1319
# Disabled warnings:
1420
# SC2001: See if you can use ${variable//search/replace} instead.

0 commit comments

Comments
 (0)