is a script that automatically updates the language settings
of different programs based on the language code passed as parameter.
This script is run by
throughout the Debian installation process so that the user language
selection is made visible to packages and thus preventing debconf
interfaces from asking questions related to language settings and
adjusting packages' system-wide configuration files to the user selection.
can run in two modes, pre-inst or post-inst (the default). Pre-inst mode
will run all scripts under /usr/lib/localization-config with a
suffix, most of these scripts will do
preseeding and will run before packages are actually installed. The
postinst mode (default) will run all scripts under the same directory with a
suffix, most of these will modify configuration files that are available
once the package has been installed on the system.
System administrators should not need to run
by hand, although this option is available. Notice, however, that running
in pre-inst mode will not affect the system unless the packages whose
debconf configuration has changed are reconfigured
(with dpkg-reconfigure PACKAGE).
Users should not run
as all the changes this script makes are systemwide.
If a user wants to change his
locale configuration and adjust the language configuration of his own
(available in the language-env package) should be used instead.
-d | --debug
-l | --list
List supported locales.
-p | --preinst
Run the pre-install scripts instead of the (default) postinst scripts.
specify your favorite native language.
Here are some of the supported languages:
Greek (Greece, UTF-8 mode)
nb_NO or no_NO (depricated)
Dutch (The Netherlands)
Support for new packages is based on scripts present in
/usr/lib/localization-config. These scripts must analyse the official
locale language code (language[_territory][.codeset][@modifier])
and modify the package as appropriate. Since language modifications
might vary between different package versions, the scripts in that
directory should just check the package version and call scripts
in per-distribution subdirectories (sarge, woody, etc.).
These scripts take as input the locale language code and should do
whatever modifications are need in order to configure the package.
Possible modifications include:
If the package asks to the user through debconf settings that
might depend on the language and charset, and if an accurate guess
can be made based on the users locale language code then the
script should preseed the debconf values so that the user will not
have to answer the questions himself upon package installation.
Debconf preseeding is usually done in the preinst phase.
configuration file modification
If the package has configuration files that can be modified to
adjust for the user's selection of locale language code, the
script should make any reasonable changes in order to help the user
configure the package. Conffiles (see Debian policy) should
be treated with extreme care (to avoid prompts of configuration file
changes by dpkg when upgrading).
All changes done by the scripts should be idempotent.
Language support is embedded in the scripts available at
/usr/lib/localization-config. These scripts hold the knowledge
on how to transform a given language code into a package's modification.
Adding support for a new language (or variant) should be done by
modifying these scripts. The code presently available that provides
support for some languages could be used as a basis for new language
support. In many scripts, adding support for a new language is just
a matter of defining it and the values that need to be changed for it
in a database of languages and changes (actually implemented
in most cases as hash array in Perl)
Location of the scripts that adjust programs to use the user configured locale.
Bugs regarding this software should be sent against the
package, preferably using the
This software and a first version of the manpage was written by
Dagfinn Ilmari Mannsaaker <email@example.com> for the Skolelinux
distribution. This manpage was later modified for the Debian GNU/Linux by
Javier Fernandez-Sanguino. Minor changes by Konstantinos Margaritis