Skip to content

Instantly share code, notes, and snippets.

@NathanaelGandhi
Last active June 8, 2023 22:44
Show Gist options
  • Save NathanaelGandhi/4fc0b01d4b1cb32c1f47ed10ba9d4f9d to your computer and use it in GitHub Desktop.
Save NathanaelGandhi/4fc0b01d4b1cb32c1f47ed10ba9d4f9d to your computer and use it in GitHub Desktop.
bash function to setup locale information
#!/bin/bash -eu
# author: Nathanael Gandhi
# github.com/NathanaelGandhi
################################################################################
# setup locale information #
################################################################################
setupLocale()
{
locale_id=en_AU.UTF-8
echo " • Setup locale default ($locale_id)"
apt-get install -y locales
locale-gen "$locale_id"
update-locale "$locale_id"
export LANG="$locale_id"
export LC_ALL="$local_id"
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment