Commit b786a82c authored by Anton Midyukov's avatar Anton Midyukov

l10n: fix setup language without alterator-sysconfig

parent f166b2f2
...@@ -7,19 +7,18 @@ locale="$GLOBAL_LOCALE" ...@@ -7,19 +7,18 @@ locale="$GLOBAL_LOCALE"
systemd_locale=/etc/locale.conf systemd_locale=/etc/locale.conf
sysv_locale=/etc/sysconfig/i18n sysv_locale=/etc/sysconfig/i18n
[ -f "$langlist" ] || exit 0 if [ -f "$langlist" ] && [ -n "$locales" ]; then
[ -n "$locales" ] || exit 0 rm -f "$langlist_temp"
rm -f "$langlist_temp" for lang in $locales; do
for lang in $locales; do
grep -q "$lang" "$langlist" && grep "$lang" "$langlist" >> "$langlist_temp" grep -q "$lang" "$langlist" && grep "$lang" "$langlist" >> "$langlist_temp"
done done
mv "$langlist_temp" "$langlist"
[ -n "$locale" ] || exit 0 mv "$langlist_temp" "$langlist"
fi
echo LANG="$locale".UTF8 > "$systemd_locale" if [ -n "$locale" ]; then
echo LANG="$locale".UTF8 > "$sysv_locale" echo LANG="$locale".UTF8 > "$systemd_locale"
echo SUPPORTED="$locale".UTF8 >> "$sysv_locale" echo LANG="$locale".UTF8 > "$sysv_locale"
echo SUPPORTED="$locale".UTF8 >> "$sysv_locale"
fi
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment