diff options
author | wxiaoguang <wxiaoguang@gmail.com> | 2022-04-03 17:46:48 +0800 |
---|---|---|
committer | GitHub <noreply@github.com> | 2022-04-03 17:46:48 +0800 |
commit | d242511e86c3a6d8a7013100845d2cdc8eb5252c (patch) | |
tree | 391b7fa946d32b44f06a274453e4b4d1a19fe8ee /custom/conf | |
parent | 27c34dd011cceb8232d1c3307f87b53a147c75c3 (diff) | |
download | gitea-d242511e86c3a6d8a7013100845d2cdc8eb5252c.tar.gz gitea-d242511e86c3a6d8a7013100845d2cdc8eb5252c.zip |
Remove legacy unmaintained packages, refactor to support change default locale (#19308)
Remove two unmaintained vendor packages `i18n` and `paginater`. Changes:
* Rewrite `i18n` package with a more clear fallback mechanism. Fix an unstable `Tr` behavior, add more tests.
* Refactor the legacy `Paginater` to `Paginator`, test cases are kept unchanged.
Trivial enhancement (no breaking for end users):
* Use the first locale in LANGS setting option as the default, add a log to prevent from surprising users.
Diffstat (limited to 'custom/conf')
-rw-r--r-- | custom/conf/app.example.ini | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/custom/conf/app.example.ini b/custom/conf/app.example.ini index 8cc22f1d14..822be00bae 100644 --- a/custom/conf/app.example.ini +++ b/custom/conf/app.example.ini @@ -2117,6 +2117,7 @@ PATH = ;[i18n] ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; +;; The first locale will be used as the default if user browser's language doesn't match any locale in the list. ;LANGS = en-US,zh-CN,zh-HK,zh-TW,de-DE,fr-FR,nl-NL,lv-LV,ru-RU,uk-UA,ja-JP,es-ES,pt-BR,pt-PT,pl-PL,bg-BG,it-IT,fi-FI,tr-TR,cs-CZ,sr-SP,sv-SE,ko-KR,el-GR,fa-IR,hu-HU,id-ID,ml-IN ;NAMES = English,简体中文,繁體中文(香港),繁體中文(台灣),Deutsch,français,Nederlands,latviešu,русский,Українська,日本語,español,português do Brasil,Português de Portugal,polski,български,italiano,suomi,Türkçe,čeština,српски,svenska,한국어,ελληνικά,فارسی,magyar nyelv,bahasa Indonesia,മലയാളം |