GRM-86: feat: add Polish as officially supported language
This commit is contained in:
@@ -1,7 +1,7 @@
|
||||
"""Simple i18n for GRM console messages.
|
||||
|
||||
Set GRM_LANG environment variable to override the default English.
|
||||
Supported: en, bg, de, ru, zh.
|
||||
Supported: en, bg, de, ru, zh, pl.
|
||||
"""
|
||||
|
||||
from __future__ import annotations
|
||||
@@ -22,7 +22,7 @@ def _(key: str, **kwargs: object) -> str:
|
||||
If unset, English is always returned regardless of system locale.
|
||||
"""
|
||||
lang = os.getenv("GRM_LANG", "en")
|
||||
if lang not in ("en", "bg", "de", "ru", "zh"):
|
||||
if lang not in ("en", "bg", "de", "ru", "zh", "pl"):
|
||||
lang = "en"
|
||||
template = TRANSLATIONS.get(key, {}).get(lang, key)
|
||||
return template.format(**kwargs)
|
||||
|
||||
Reference in New Issue
Block a user