1#!/bin/sh
2# SPDX-License-Identifier: LGPL-2.1-or-later
3set -e
4
5# Fedora uses C.utf8 but Debian uses C.UTF-8
6if locale -a | grep -xq -E 'C\.(utf8|UTF-8)'; then
7    echo 'C.UTF-8'
8elif locale -a | grep -xqF 'en_US.utf8'; then
9    echo 'en_US.UTF-8'
10else
11    echo 'C'
12fi
13