Use naked en locale instead of en_US. Fixes #623 (#626)

This commit is contained in:
Manu 2020-09-08 08:22:26 +08:00 committed by GitHub
parent 4eafad5472
commit 1d65d0cba5
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
5 changed files with 7 additions and 7 deletions

2
.gitignore vendored
View File

@ -16,7 +16,7 @@ vorta.egg-info
*.log
htmlcov
*.qm
src/vorta/i18n/ts/vorta.en_US.ts
src/vorta/i18n/ts/vorta.en.ts
flatpak/app/
flatpak/.flatpak-builder/

View File

@ -4,7 +4,7 @@ host = https://www.transifex.com
[vorta.vorta]
file_filter = src/vorta/i18n/ts/vorta.<lang>.ts
minimum_perc = 80
source_file = src/vorta/i18n/ts/vorta.en_US.ts
source_lang = en_US
source_file = src/vorta/i18n/ts/vorta.en.ts
source_lang = en
type = QT

View File

@ -1,7 +1,7 @@
graft src/vorta/assets
# Include all compiled .qm language files, but exclude the source language (en_US).
# Include all compiled .qm language files, but exclude the source language (en).
recursive-include src/vorta/i18n/qm *.qm
exclude src/vorta/i18n/qm/vorta.en_US.qm
exclude src/vorta/i18n/qm/vorta.en.qm
recursive-exclude tests *

View File

@ -47,7 +47,7 @@ translations-from-source: ## Extract strings from source code / UI files, merge
pylupdate5 -verbose -translate-function trans_late \
$$VORTA_SRC/*.py $$VORTA_SRC/views/*.py $$VORTA_SRC/borg/*.py \
$$VORTA_SRC/assets/UI/*.ui \
-ts $$VORTA_SRC/i18n/ts/vorta.en_US.ts
-ts $$VORTA_SRC/i18n/ts/vorta.en.ts
translations-push: translations-from-source ## Upload .ts to Transifex.
tx push -s

View File

@ -49,7 +49,7 @@ def local_en():
Some tests use English strings. So override whatever language the current user
has and run the tests with the English UI.
"""
os.environ['LANG'] = 'en_US'
os.environ['LANG'] = 'en'
@pytest.fixture(scope='session')