when the user's locale is misconfigured, set it to utf8 at the top level

fixes #469
This commit is contained in:
romkatv 2020-02-05 12:50:51 +01:00
commit a12f7ac8ee
4 changed files with 27 additions and 28 deletions

View file

@ -1,10 +1,3 @@
zmodload zsh/langinfo
if [[ ${langinfo[CODESET]:-} != (utf|UTF)(-|)8 ]]; then
local LC_ALL=${${(@M)$(locale -a):#*.(utf|UTF)(-|)8}[1]:-en_US.UTF-8}
fi
zmodload -F zsh/files b:zf_mv b:zf_rm
local -i force=0
local opt