Setting the correct locale

This one has caused my some head aches; I wanted to use ISO-8859-1(5) but no matter what I did, GNOME Terminal would select ANSI_X3.4-1968 as character encoding (screwing up everything related to danish characters).

The solution:

  1. Create or edit the file

    /var/lib/locales/supported.d/local

    en_DK ISO-8859-15
  2. Regenerate locales:

    $ sudo locale-gen --purge
    Generating locales...
      en_AU.UTF-8... done
      en_BW.UTF-8... done
      en_CA.UTF-8... done
      en_DK.ISO-8859-15... done
      en_DK.UTF-8... done
      en_GB.UTF-8... done
      en_HK.UTF-8... done
      en_IE.UTF-8... done
      en_IN.UTF-8... done
      en_NZ.UTF-8... done
      en_PH.UTF-8... done
      en_SG.UTF-8... done
      en_US.UTF-8... done
      en_ZA.UTF-8... done
      en_ZW.UTF-8... done
    Generation complete.
  3. Log out and from GDM select language “English (Denmark)” and answer yes