Skip to content

Instantly share code, notes, and snippets.

Show Gist options
  • Save themagic314/8c1ac3087eb385d40eb41c1f43651b3e to your computer and use it in GitHub Desktop.
Save themagic314/8c1ac3087eb385d40eb41c1f43651b3e to your computer and use it in GitHub Desktop.
Raspberry Pi: Reconfigure Locales

Reconfigure your RPi Locales

First you need to install the locales you want:

sudo dpkg-reconfigure locales

Then refresh your current environment:

export LANGUAGE=en_US.UTF-8
export LANG=en_US.UTF-8
export LC_ALL=en_US.UTF-8
sudo locale-gen en_US.UTF-8

If you see these errors (on Jessie Lite) follow the next step

locale: Cannot set LC_CTYPE to default locale: No such file or directory
locale: Cannot set LC_ALL to default locale: No such file or directory

Open your environment file

sudo nano /etc/environment

Add these lines

LC_ALL=en_US.UTF-8
LANG=en_US.UTF-8

Ctrl+X, Y and Enter to Save

That's it.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment