From 5d836e38deafbc1666a12dcf1fc5b2ba8fd277e6 Mon Sep 17 00:00:00 2001 From: oreo639 Date: Tue, 13 Sep 2022 10:22:19 -0700 Subject: [PATCH] base-files: don't overwrite existing locale and define default LANG --- srcpkgs/base-files/files/locale.sh | 10 ++++++++-- srcpkgs/base-files/template | 2 +- 2 files changed, 9 insertions(+), 3 deletions(-) diff --git a/srcpkgs/base-files/files/locale.sh b/srcpkgs/base-files/files/locale.sh index 8486367bfabf..bf266eefa1d1 100644 --- a/srcpkgs/base-files/files/locale.sh +++ b/srcpkgs/base-files/files/locale.sh @@ -1,9 +1,15 @@ # Sets up locale system settings from /etc/locale.conf. # -if [ -s /etc/locale.conf ]; then - . /etc/locale.conf + +if [ -z "$LANG" ]; then + if [ -s /etc/locale.conf ]; then + . /etc/locale.conf + fi fi +# define default LANG to C if not already defined +LANG=${LANG:-C} + export LANG LANGUAGE LC_CTYPE LC_NUMERIC LC_TIME LC_COLLATE LC_MONETARY export LC_MESSAGES LC_PAPER LC_NAME LC_ADDRESS LC_TELEPHONE LC_MEASUREMENT export LC_INDENTIFICATION diff --git a/srcpkgs/base-files/template b/srcpkgs/base-files/template index be6384f942c6..f4d9085b32e4 100644 --- a/srcpkgs/base-files/template +++ b/srcpkgs/base-files/template @@ -1,7 +1,7 @@ # Template file for 'base-files' pkgname=base-files version=0.142 -revision=14 +revision=15 bootstrap=yes depends="xbps-triggers" short_desc="Void Linux base system files"