Skip to content

Commit dfb8fee

Browse files
fendormichaelpj
andauthored
Remove locale workaround for Module name that conatins non-ascii characters (#4106)
Co-authored-by: Michael Peyton Jones <[email protected]>
1 parent 829e1f4 commit dfb8fee

File tree

2 files changed

+0
-32
lines changed

2 files changed

+0
-32
lines changed

.github/scripts/build.sh

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -11,9 +11,6 @@ uname
1111
pwd
1212
env
1313

14-
# setup the locale as HLS contains non-ascii modules and content.
15-
setup_locale
16-
1714
# ensure ghcup
1815
install_ghcup
1916

.github/scripts/common.sh

Lines changed: 0 additions & 29 deletions
Original file line numberDiff line numberDiff line change
@@ -207,32 +207,3 @@ mktempdir() {
207207
;;
208208
esac
209209
}
210-
211-
# "Inspired" from GHC GitLab CI
212-
# https://gitlab.haskell.org/ghc/ghc/-/blob/214b2b6916f2d016ab9db0b766060e7828bb47a0/.gitlab/ci.sh#L60
213-
setup_locale() {
214-
# BSD grep terminates early with -q, consequently locale -a will get a
215-
# SIGPIPE and the pipeline will fail with pipefail.
216-
shopt -o -u pipefail
217-
if locale -a | grep -q C.UTF-8; then
218-
# Debian
219-
export LANG=C.UTF-8
220-
elif locale -a | grep -q C.utf8; then
221-
# Fedora calls it this
222-
export LANG=C.utf8
223-
elif locale -a | grep -q en_US.UTF-8; then
224-
# Centos doesn't have C.UTF-8
225-
export LANG=en_US.UTF-8
226-
elif locale -a | grep -q en_US.utf8; then
227-
# Centos doesn't have C.UTF-8
228-
export LANG=en_US.utf8
229-
else
230-
error "Failed to find usable locale"
231-
info "Available locales:"
232-
locale -a
233-
fail "No usable locale, aborting..."
234-
fi
235-
info "Using locale $LANG..."
236-
export LC_ALL=$LANG
237-
shopt -o -s pipefail
238-
}

0 commit comments

Comments
 (0)