fix issue where placeholder fr_FR.UTF-8 wasn't replaced with DEBLANGUAGE

This commit is contained in:
Alex Bradbury 2013-09-25 18:16:19 +01:00
parent fa44ce461e
commit 84ae83fd7a

View File

@ -623,15 +623,14 @@ do_apply_os_config() {
if [ -n "$DEBLANGUAGE" ]; then if [ -n "$DEBLANGUAGE" ]; then
printf "Setting language to %s based on os_config.json from NOOBS. May take a while\n" "$DEBLANGUAGE" printf "Setting language to %s based on os_config.json from NOOBS. May take a while\n" "$DEBLANGUAGE"
# TODO: map noobs language to Debian spec
cat << EOF | debconf-set-selections cat << EOF | debconf-set-selections
locales locales/locales_to_be_generated multiselect fr_FR.UTF-8 UTF-8 locales locales/locales_to_be_generated multiselect $DEBLANGUAGE UTF-8
EOF EOF
rm /etc/locale.gen rm /etc/locale.gen
dpkg-reconfigure -f noninteractive locales dpkg-reconfigure -f noninteractive locales
update-locale LANG=fr_FR.UTF-8 update-locale LANG="$DEBLANGUAGE"
cat << EOF | debconf-set-selections cat << EOF | debconf-set-selections
locales locales/default_environment_locale select fr_FR.UTF-8 locales locales/default_environment_locale select $DEBLANGUAGE
EOF EOF
fi fi