Add EUC-JP locale name normalization
The function normalizes checks for UTF-8, but the same issue exists for other locales as well. This fix adds normalization for EUC-JP, a Japanese locale.
This commit is contained in:
parent
e6eb7d47eb
commit
0ac3592b92
1 changed files with 1 additions and 1 deletions
|
@ -44,7 +44,7 @@ def is_present(name):
|
||||||
def fix_case(name):
|
def fix_case(name):
|
||||||
"""locale -a might return the encoding in either lower or upper case.
|
"""locale -a might return the encoding in either lower or upper case.
|
||||||
Passing through this function makes them uniform for comparisons."""
|
Passing through this function makes them uniform for comparisons."""
|
||||||
return name.replace(".utf8", ".UTF-8")
|
return name.replace(".utf8", ".UTF-8").replace(".eucjp", ".EUC-JP")
|
||||||
|
|
||||||
def replace_line(existing_line, new_line):
|
def replace_line(existing_line, new_line):
|
||||||
"""Replaces lines in /etc/locale.gen"""
|
"""Replaces lines in /etc/locale.gen"""
|
||||||
|
|
Loading…
Reference in a new issue