diff --git a/spcd/bootstrap.sh b/spcd/bootstrap.sh index ba26ddc..ae8d7ec 100644 --- a/spcd/bootstrap.sh +++ b/spcd/bootstrap.sh @@ -1180,21 +1180,20 @@ spcd_step__packages_install_locales() { case "${SPCD_PM}" in "${SPCD_PM_APK}") spcd_install_package "musl-locales" ;; "${SPCD_PM_APT}") - unset spcd_step__pil__text - for spcd_step__pil__locale in "${@}"; do - spcd_step__pil__text="${spcd_step__pil__text}\ -${spcd_step__pil__locale}.${_SPCD_TXT_CHARSET} ${_SPCD_TXT_CHARSET} + local locale text + for locale in "${@}"; do + text="${text}\ +${locale}.${_SPCD_TXT_CHARSET} ${_SPCD_TXT_CHARSET} " done - spcd_os_write "/etc/locale.gen" "${spcd_step__pil__text}" + spcd_os_write "/etc/locale.gen" "${text}" spcd_install_package "locales" ;; "${SPCD_PM_DNF}") - for spcd_step__pil__locale in "${@}"; do - spcd_step__pil__lang="$( - echo "${spcd_step__pil__locale}" | cut -d _ -f 1 - )" - spcd_install_package "glibc-langpack-${spcd_step__pil__lang}" + local locale language + for locale in "${@}"; do + language="$(echo "${locale}" | cut -d _ -f 1)" + spcd_install_package "glibc-langpack-${language}" done ;; "${SPCD_PM_PACMAN}") spcd_install_package "glibc-locales" ;;