diff options
author | B. Stack <bgstack15@gmail.com> | 2022-03-05 15:36:37 -0500 |
---|---|---|
committer | B. Stack <bgstack15@gmail.com> | 2022-03-05 15:36:37 -0500 |
commit | 36846794abebbb98bb0d960398ff55c66856c64a (patch) | |
tree | 75cbb4fc2795294276bfdd91fad93e2a6889131e /debian/locale-en-bs.postinst | |
parent | initial commit (diff) | |
download | locale-en_BS-36846794abebbb98bb0d960398ff55c66856c64a.tar.gz locale-en_BS-36846794abebbb98bb0d960398ff55c66856c64a.tar.bz2 locale-en_BS-36846794abebbb98bb0d960398ff55c66856c64a.zip |
add dpkg recipe and readme
Diffstat (limited to 'debian/locale-en-bs.postinst')
-rw-r--r-- | debian/locale-en-bs.postinst | 28 |
1 files changed, 28 insertions, 0 deletions
diff --git a/debian/locale-en-bs.postinst b/debian/locale-en-bs.postinst new file mode 100644 index 0000000..5ff1e25 --- /dev/null +++ b/debian/locale-en-bs.postinst @@ -0,0 +1,28 @@ +#!/bin/sh +# Reference: +# https://askubuntu.com/questions/21316/how-can-i-customize-a-system-locale +set -e + +fix1() { + grep -qe 'en_BS UTF-8' $1 || echo 'en_BS UTF-8' >> $1 + grep -qe 'en_BS.UTF-8 UTF-8' $1 || echo 'en_BS.UTF-8 UTF-8' >> $1 +} + +case "$1" in + configure|abort-upgrade|abort-remove|abort-deconfigure) + localedef --quiet --force --inputfile /usr/share/i18n/locales/en_BS --charmap UTF-8 en_BS.utf8 + fix1 /usr/share/i18n/SUPPORTED + fix1 /etc/locale.gen + locale-gen + update-locale LC_TIME=en_BS + ;; + + *) + echo "postinst called with unknown argument '\$1'" 1>&2 + exit 1 + ;; +esac + +#DEBHELPER# + +exit 0 |