diff options
author | wxiaoguang <wxiaoguang@gmail.com> | 2023-03-31 12:16:41 +0800 |
---|---|---|
committer | GitHub <noreply@github.com> | 2023-03-31 12:16:41 +0800 |
commit | 288c2e8c48991e5e425fd5ffe1959f4b3d0b675a (patch) | |
tree | 831ad0b2bd2da5435a8a53f6cee0f03540bcd242 /build | |
parent | d5feb10aca0b309dce17a13255b4030f0a0cfe1b (diff) | |
download | gitea-288c2e8c48991e5e425fd5ffe1959f4b3d0b675a.tar.gz gitea-288c2e8c48991e5e425fd5ffe1959f4b3d0b675a.zip |
Clarify Gitea/Crowdin locale behaviors, add tests for LocaleStore, fix some strings with semicolons (#23819)
Follow #23633 and #23240
Close #23814
Now we almost have a complete test set for Gitea's LocalStore.
This PR is still a quick fix for the legacy locale system (see the
TODOs), to resolve the problems fundamentally, it needs more work in the
future.
Diffstat (limited to 'build')
-rwxr-xr-x | build/update-locales.sh | 15 |
1 files changed, 4 insertions, 11 deletions
diff --git a/build/update-locales.sh b/build/update-locales.sh index 596ddfec03..6f9ee334be 100755 --- a/build/update-locales.sh +++ b/build/update-locales.sh @@ -17,17 +17,10 @@ fi mv ./options/locale/locale_en-US.ini ./options/ -# the "ini" library for locale has many quirks -# * `a="xx"` gets `xx` (no quote) -# * `a=x\"y` gets `x\"y` (no unescaping) -# * `a="x\"y"` gets `"x\"y"` (no unescaping, the quotes are still there) -# * `a='x\"y'` gets `x\"y` (no unescaping, no quote) -# * `a="foo` gets `"foo` (although the quote is not closed) -# * 'a=`foo`' works like single-quote -# crowdin needs the strings to be quoted correctly and doesn't like incomplete quotes -# crowdin always outputs quoted strings if there are quotes in the strings. - -# this script helps to unquote the crowdin outputs for the quirky ini library +# the "ini" library for locale has many quirks, its behavior is different from Crowdin. +# see i18n_test.go for more details + +# this script helps to unquote the Crowdin outputs for the quirky ini library # * find all `key="...\"..."` lines # * remove the leading quote # * remove the trailing quote |