Skip to content
Snippets Groups Projects
Unverified Commit 0401c533 authored by Grace Hawkins's avatar Grace Hawkins Committed by GitHub
Browse files

Complete language codes list (#1197)

parent 16213940
No related branches found
No related tags found
No related merge requests found
...@@ -5,6 +5,7 @@ ...@@ -5,6 +5,7 @@
# Copyright © 2014-2017 Stefano Maggiolo <s.maggiolo@gmail.com> # Copyright © 2014-2017 Stefano Maggiolo <s.maggiolo@gmail.com>
# Copyright © 2018 Edoardo Morassutto <edoardo.morassutto@gmail.com> # Copyright © 2018 Edoardo Morassutto <edoardo.morassutto@gmail.com>
# Copyright © 2018 Luca Wehrstedt <luca.wehrstedt@gmail.com> # Copyright © 2018 Luca Wehrstedt <luca.wehrstedt@gmail.com>
# Copyright © 2021 Grace Hawkins <amoomajid99@gmail.com>
# #
# This program is free software: you can redistribute it and/or modify # This program is free software: you can redistribute it and/or modify
# it under the terms of the GNU Affero General Public License as # it under the terms of the GNU Affero General Public License as
...@@ -40,8 +41,68 @@ def make_timedelta(t): ...@@ -40,8 +41,68 @@ def make_timedelta(t):
return timedelta(seconds=t) return timedelta(seconds=t)
# TODO: add all languages. LANGUAGE_MAP = {
LANGUAGE_MAP = {'english': 'en', 'russian': 'ru', 'italian': 'it'} 'afrikaans': 'af',
'arabic': 'ar',
'armenian': 'hy',
'azerbaijani': 'az',
'belarusian': 'be',
'bengali': 'bn',
'bosnian': 'bs',
'bulgarian': 'bg',
'catalan': 'ca',
'chinese': 'zh',
'croatian': 'hr',
'czech': 'cs',
'danish': 'da',
'dutch': 'nl',
'english': 'en',
'estonian': 'et',
'filipino': 'fil',
'finnish': 'fi',
'french': 'fr',
'georgian': 'ka',
'german': 'de',
'greek': 'el',
'hebrew': 'he',
'hindi': 'hi',
'hungarian': 'hu',
'icelandic': 'is',
'indonesian': 'id',
'irish': 'ga',
'italian': 'it',
'japanese': 'ja',
'kazakh': 'kk',
'korean': 'ko',
'kyrgyz': 'ky',
'latvian': 'lv',
'lithuanian': 'lt',
'macedonian': 'mk',
'malay': 'ms',
'mongolian': 'mn',
'norwegian': 'no',
'persian': 'fa',
'polish': 'pl',
'portuguese': 'pt',
'romanian': 'ro',
'russian': 'ru',
'serbian': 'sr',
'sinhala': 'si',
'slovak': 'sk',
'slovene': 'sl',
'spanish': 'es',
'swedish': 'sv',
'tajik': 'tg',
'tamil': 'ta',
'thai': 'th',
'turkish': 'tr',
'turkmen': 'tk',
'ukrainian': 'uk',
'urdu': 'ur',
'uzbek': 'uz',
'vietnamese': 'vi',
'other': 'other',
}
class PolygonTaskLoader(TaskLoader): class PolygonTaskLoader(TaskLoader):
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment