mirror of
https://gitlab.archlinux.org/tpowa/archboot.git
synced 2024-09-20 12:00:37 +02:00
add locale.gen adoption if systemd is used
This commit is contained in:
parent
3f524a500a
commit
81d549abb0
1 changed files with 11 additions and 4 deletions
|
@ -5313,10 +5313,17 @@ configure_system() {
|
||||||
DIALOG --msgbox "ERROR: Detected error in 'HOOKS=' line, please correct HOOKS= in /etc/mkinitcpio.conf!" 18 70
|
DIALOG --msgbox "ERROR: Detected error in 'HOOKS=' line, please correct HOOKS= in /etc/mkinitcpio.conf!" 18 70
|
||||||
fi
|
fi
|
||||||
elif [[ "${FILE}" = "/etc/locale.gen" ]]; then # non-file
|
elif [[ "${FILE}" = "/etc/locale.gen" ]]; then # non-file
|
||||||
|
if [[ "${SYSTEMD}" = "1" ]]; then
|
||||||
|
# enable glibc locales from locale.conf
|
||||||
|
for i in $(grep "^LANG" ${DESTDIR}/etc/locale.conf | sed -e 's/.*="//g' -e's/\..*//g'); do
|
||||||
|
sed -i -e "s/^#${i}/${i}/g" ${DESTDIR}/etc/locale.gen
|
||||||
|
done
|
||||||
|
else
|
||||||
# enable glibc locales from rc.conf
|
# enable glibc locales from rc.conf
|
||||||
for i in $(grep "^LOCALE" ${DESTDIR}/etc/rc.conf | sed -e 's/.*="//g' -e's/\..*//g'); do
|
for i in $(grep "^LOCALE" ${DESTDIR}/etc/rc.conf | sed -e 's/.*="//g' -e's/\..*//g'); do
|
||||||
sed -i -e "s/^#${i}/${i}/g" ${DESTDIR}/etc/locale.gen
|
sed -i -e "s/^#${i}/${i}/g" ${DESTDIR}/etc/locale.gen
|
||||||
done
|
done
|
||||||
|
fi
|
||||||
${EDITOR} ${DESTDIR}${FILE}
|
${EDITOR} ${DESTDIR}${FILE}
|
||||||
elif [[ "${FILE}" = "Root-Password" ]]; then # non-file
|
elif [[ "${FILE}" = "Root-Password" ]]; then # non-file
|
||||||
PASSWORD=""
|
PASSWORD=""
|
||||||
|
|
Loading…
Reference in a new issue