From 29ab56500a533eafb2a4bbc0bf909f5a8e738d2e Mon Sep 17 00:00:00 2001 From: Konstantin Freidlin Date: Fri, 2 Sep 2022 19:13:58 +0300 Subject: [PATCH 1/4] Add achievements feature (icons / update template and view) --- contributors/views/contributor.py | 1 + .../achievments_icons/code_editioins-1000.svg | 41 +++++ .../achievments_icons/code_edition-1.svg | 9 + .../achievments_icons/code_editions-100.svg | 28 ++++ .../achievments_icons/code_editions-250.svg | 32 ++++ .../achievments_icons/code_editions-500.svg | 36 ++++ static/images/achievments_icons/comment-1.svg | 7 + .../images/achievments_icons/comments-100.svg | 23 +++ .../images/achievments_icons/comments-200.svg | 25 +++ .../images/achievments_icons/comments-25.svg | 18 ++ .../images/achievments_icons/comments-50.svg | 20 +++ static/images/achievments_icons/commit-1.svg | 7 + .../images/achievments_icons/commits-100.svg | 23 +++ .../images/achievments_icons/commits-200.svg | 25 +++ .../images/achievments_icons/commits-25.svg | 18 ++ .../images/achievments_icons/commits-50.svg | 20 +++ static/images/achievments_icons/friend.svg | 11 ++ static/images/achievments_icons/issue-1.svg | 7 + static/images/achievments_icons/issues-10.svg | 22 +++ static/images/achievments_icons/issues-25.svg | 24 +++ static/images/achievments_icons/issues-5.svg | 19 +++ static/images/achievments_icons/issues-50.svg | 26 +++ .../achievments_icons/pull_request-1.svg | 7 + .../achievments_icons/pull_requests-10.svg | 19 +++ .../achievments_icons/pull_requests-100.svg | 26 +++ .../achievments_icons/pull_requests-25.svg | 21 +++ .../achievments_icons/pull_requests-50.svg | 23 +++ templates/contributor_details.html | 154 +++++++++++++++++- 28 files changed, 690 insertions(+), 2 deletions(-) create mode 100644 static/images/achievments_icons/code_editioins-1000.svg create mode 100644 static/images/achievments_icons/code_edition-1.svg create mode 100644 static/images/achievments_icons/code_editions-100.svg create mode 100644 static/images/achievments_icons/code_editions-250.svg create mode 100644 static/images/achievments_icons/code_editions-500.svg create mode 100644 static/images/achievments_icons/comment-1.svg create mode 100644 static/images/achievments_icons/comments-100.svg create mode 100644 static/images/achievments_icons/comments-200.svg create mode 100644 static/images/achievments_icons/comments-25.svg create mode 100644 static/images/achievments_icons/comments-50.svg create mode 100644 static/images/achievments_icons/commit-1.svg create mode 100644 static/images/achievments_icons/commits-100.svg create mode 100644 static/images/achievments_icons/commits-200.svg create mode 100644 static/images/achievments_icons/commits-25.svg create mode 100644 static/images/achievments_icons/commits-50.svg create mode 100644 static/images/achievments_icons/friend.svg create mode 100644 static/images/achievments_icons/issue-1.svg create mode 100644 static/images/achievments_icons/issues-10.svg create mode 100644 static/images/achievments_icons/issues-25.svg create mode 100644 static/images/achievments_icons/issues-5.svg create mode 100644 static/images/achievments_icons/issues-50.svg create mode 100644 static/images/achievments_icons/pull_request-1.svg create mode 100644 static/images/achievments_icons/pull_requests-10.svg create mode 100644 static/images/achievments_icons/pull_requests-100.svg create mode 100644 static/images/achievments_icons/pull_requests-25.svg create mode 100644 static/images/achievments_icons/pull_requests-50.svg diff --git a/contributors/views/contributor.py b/contributors/views/contributor.py index b6392d56..5078094a 100644 --- a/contributors/views/contributor.py +++ b/contributors/views/contributor.py @@ -11,6 +11,7 @@ class DetailView(generic.DetailView): model = Contributor template_name = 'contributor_details.html' slug_field = 'login' + queryset = Contributor.objects.with_contributions() def get_context_data(self, **kwargs): """Add additional context for the contributor.""" diff --git a/static/images/achievments_icons/code_editioins-1000.svg b/static/images/achievments_icons/code_editioins-1000.svg new file mode 100644 index 00000000..7aba9e26 --- /dev/null +++ b/static/images/achievments_icons/code_editioins-1000.svg @@ -0,0 +1,41 @@ + + + achievement-code_editioins-1000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/static/images/achievments_icons/code_edition-1.svg b/static/images/achievments_icons/code_edition-1.svg new file mode 100644 index 00000000..aec9ad5e --- /dev/null +++ b/static/images/achievments_icons/code_edition-1.svg @@ -0,0 +1,9 @@ + + + achievement-code_edition-1 + + + + + + \ No newline at end of file diff --git a/static/images/achievments_icons/code_editions-100.svg b/static/images/achievments_icons/code_editions-100.svg new file mode 100644 index 00000000..d9148062 --- /dev/null +++ b/static/images/achievments_icons/code_editions-100.svg @@ -0,0 +1,28 @@ + + + achievement-code_editions-100 + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/static/images/achievments_icons/code_editions-250.svg b/static/images/achievments_icons/code_editions-250.svg new file mode 100644 index 00000000..061840aa --- /dev/null +++ b/static/images/achievments_icons/code_editions-250.svg @@ -0,0 +1,32 @@ + + + achievement-code_editions-250 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/static/images/achievments_icons/code_editions-500.svg b/static/images/achievments_icons/code_editions-500.svg new file mode 100644 index 00000000..e763f0b2 --- /dev/null +++ b/static/images/achievments_icons/code_editions-500.svg @@ -0,0 +1,36 @@ + + + achievement-code_editions-500 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/static/images/achievments_icons/comment-1.svg b/static/images/achievments_icons/comment-1.svg new file mode 100644 index 00000000..0cd98e6e --- /dev/null +++ b/static/images/achievments_icons/comment-1.svg @@ -0,0 +1,7 @@ + + + achievement-comment-1 + + + + \ No newline at end of file diff --git a/static/images/achievments_icons/comments-100.svg b/static/images/achievments_icons/comments-100.svg new file mode 100644 index 00000000..d68b44a1 --- /dev/null +++ b/static/images/achievments_icons/comments-100.svg @@ -0,0 +1,23 @@ + + + achievement-comments-100 + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/static/images/achievments_icons/comments-200.svg b/static/images/achievments_icons/comments-200.svg new file mode 100644 index 00000000..2c330cb6 --- /dev/null +++ b/static/images/achievments_icons/comments-200.svg @@ -0,0 +1,25 @@ + + + achievement-comments-200 + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/static/images/achievments_icons/comments-25.svg b/static/images/achievments_icons/comments-25.svg new file mode 100644 index 00000000..89618a98 --- /dev/null +++ b/static/images/achievments_icons/comments-25.svg @@ -0,0 +1,18 @@ + + + achievement-comments-25 + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/static/images/achievments_icons/comments-50.svg b/static/images/achievments_icons/comments-50.svg new file mode 100644 index 00000000..2da54061 --- /dev/null +++ b/static/images/achievments_icons/comments-50.svg @@ -0,0 +1,20 @@ + + + achievement-comments-50 + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/static/images/achievments_icons/commit-1.svg b/static/images/achievments_icons/commit-1.svg new file mode 100644 index 00000000..07c4ff81 --- /dev/null +++ b/static/images/achievments_icons/commit-1.svg @@ -0,0 +1,7 @@ + + + achievement-commit-1 + + + + \ No newline at end of file diff --git a/static/images/achievments_icons/commits-100.svg b/static/images/achievments_icons/commits-100.svg new file mode 100644 index 00000000..935b2834 --- /dev/null +++ b/static/images/achievments_icons/commits-100.svg @@ -0,0 +1,23 @@ + + + achievement-commits-100 + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/static/images/achievments_icons/commits-200.svg b/static/images/achievments_icons/commits-200.svg new file mode 100644 index 00000000..137dfdf3 --- /dev/null +++ b/static/images/achievments_icons/commits-200.svg @@ -0,0 +1,25 @@ + + + achievement-commits-200 + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/static/images/achievments_icons/commits-25.svg b/static/images/achievments_icons/commits-25.svg new file mode 100644 index 00000000..970ba452 --- /dev/null +++ b/static/images/achievments_icons/commits-25.svg @@ -0,0 +1,18 @@ + + + achievement-commits-25 + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/static/images/achievments_icons/commits-50.svg b/static/images/achievments_icons/commits-50.svg new file mode 100644 index 00000000..314ee189 --- /dev/null +++ b/static/images/achievments_icons/commits-50.svg @@ -0,0 +1,20 @@ + + + achievement-commits-50 + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/static/images/achievments_icons/friend.svg b/static/images/achievments_icons/friend.svg new file mode 100644 index 00000000..c3b3d53b --- /dev/null +++ b/static/images/achievments_icons/friend.svg @@ -0,0 +1,11 @@ + + + friend + + + + + + + + \ No newline at end of file diff --git a/static/images/achievments_icons/issue-1.svg b/static/images/achievments_icons/issue-1.svg new file mode 100644 index 00000000..4d8ba810 --- /dev/null +++ b/static/images/achievments_icons/issue-1.svg @@ -0,0 +1,7 @@ + + + achievement-issue-1 + + + + \ No newline at end of file diff --git a/static/images/achievments_icons/issues-10.svg b/static/images/achievments_icons/issues-10.svg new file mode 100644 index 00000000..4d911a4c --- /dev/null +++ b/static/images/achievments_icons/issues-10.svg @@ -0,0 +1,22 @@ + + + achievement-issues-10 + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/static/images/achievments_icons/issues-25.svg b/static/images/achievments_icons/issues-25.svg new file mode 100644 index 00000000..33db7d13 --- /dev/null +++ b/static/images/achievments_icons/issues-25.svg @@ -0,0 +1,24 @@ + + + achievement-issues-25 + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/static/images/achievments_icons/issues-5.svg b/static/images/achievments_icons/issues-5.svg new file mode 100644 index 00000000..02dc8e8f --- /dev/null +++ b/static/images/achievments_icons/issues-5.svg @@ -0,0 +1,19 @@ + + + achievement-issues-5 + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/static/images/achievments_icons/issues-50.svg b/static/images/achievments_icons/issues-50.svg new file mode 100644 index 00000000..c1eb47a6 --- /dev/null +++ b/static/images/achievments_icons/issues-50.svg @@ -0,0 +1,26 @@ + + + achievement-issues-50 + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/static/images/achievments_icons/pull_request-1.svg b/static/images/achievments_icons/pull_request-1.svg new file mode 100644 index 00000000..5d9e7d0e --- /dev/null +++ b/static/images/achievments_icons/pull_request-1.svg @@ -0,0 +1,7 @@ + + + achievement-pull_request-1 + + + + \ No newline at end of file diff --git a/static/images/achievments_icons/pull_requests-10.svg b/static/images/achievments_icons/pull_requests-10.svg new file mode 100644 index 00000000..abc3879c --- /dev/null +++ b/static/images/achievments_icons/pull_requests-10.svg @@ -0,0 +1,19 @@ + + + achievement-pull_requests-10 + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/static/images/achievments_icons/pull_requests-100.svg b/static/images/achievments_icons/pull_requests-100.svg new file mode 100644 index 00000000..a0a4cdab --- /dev/null +++ b/static/images/achievments_icons/pull_requests-100.svg @@ -0,0 +1,26 @@ + + + achievement-pull_requests-100 + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/static/images/achievments_icons/pull_requests-25.svg b/static/images/achievments_icons/pull_requests-25.svg new file mode 100644 index 00000000..8ec06471 --- /dev/null +++ b/static/images/achievments_icons/pull_requests-25.svg @@ -0,0 +1,21 @@ + + + achievement-pull_requests-25 + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/static/images/achievments_icons/pull_requests-50.svg b/static/images/achievments_icons/pull_requests-50.svg new file mode 100644 index 00000000..98e6fbf5 --- /dev/null +++ b/static/images/achievments_icons/pull_requests-50.svg @@ -0,0 +1,23 @@ + + + achievement-pull_requests-50 + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/templates/contributor_details.html b/templates/contributor_details.html index 7a8acf17..183b29ae 100644 --- a/templates/contributor_details.html +++ b/templates/contributor_details.html @@ -18,12 +18,162 @@

{{ contributor.login }}

GitHub +

+ {% trans 'Achievments' %} +

+ + {% if contributor.additions|add:contributor.deletions|add:contributor.pull_requests|add:contributor.issues|add:contributor.comments > 0 %} + {% trans + {% endif %} + + {% if contributor.pull_requests >= 100 %} + {% trans 'Pull requests' %}: {{ contributor.pull_requests }} + {% elif contributor.pull_requests >= 50 %} + {% trans 'Pull requests' %}: {{ contributor.pull_requests }} + {% elif contributor.pull_requests >= 25 %} + {% trans 'Pull requests' %}: {{ contributor.pull_requests }} + {% elif contributor.pull_requests >= 10 %} + {% trans 'Pull requests' %}: {{ contributor.pull_requests }} + {% elif contributor.pull_requests >= 1 %} + {% trans 'Pull requests' %}: {{ contributor.pull_requests }} + {% endif %} + + {% if contributor.commits >= 200 %} + {% trans 'Commits' %}: {{ contributor.commits }} + {% elif contributor.commits >= 100 %} + {% trans 'Commits' %}: {{ contributor.commits }} + {% elif contributor.commits >= 50 %} + {% trans 'Commits' %}: {{ contributor.commits }} + {% elif contributor.commits >= 25 %} + {% trans 'Commits' %}: {{ contributor.commits }} + {% elif contributor.commits >= 1 %} + {% trans 'Commits' %}: {{ contributor.commits }} + {% endif %} + + {% if contributor.issues >= 50 %} + {% trans 'Issues' %}: {{ contributor.issues }} + {% elif contributor.issues >= 25 %} + {% trans 'Issues' %}: {{ contributor.issues }} + {% elif contributor.issues >= 10 %} + {% trans 'Issues' %}: {{ contributor.issues }} + {% elif contributor.issues >= 5 %} + {% trans 'Issues' %}: {{ contributor.issues }} + {% elif contributor.issues >= 1 %} + {% trans 'Issuess' %}: {{ contributor.issues }} + {% endif %} + + {% if contributor.comments >= 200 %} + {% trans 'Comments' %}: {{ contributor.comments }} + {% elif contributor.comments >= 100 %} + {% trans 'Comments' %}: {{ contributor.comments }} + {% elif contributor.comments >= 50 %} + {% trans 'Comments' %}: {{ contributor.comments }} + {% elif contributor.comments >= 25 %} + {% trans 'Comments' %}: {{ contributor.comments }} + {% elif contributor.comments >= 1 %} + {% trans 'Comments' %}: {{ contributor.comments }} + {% endif %} + + {% if contributor.additions|add:contributor.deletions >= 1000 %} + {% trans 'Additions and deletions' %}: {{ contributor.additions|add:contributor.deletions }} + {% elif contributor.additions|add:contributor.deletions >= 500 %} + {% trans 'Additions and deletions' %}: {{ contributor.additions|add:contributor.deletions }} + {% elif contributor.additions|add:contributor.deletions >= 250 %} + {% trans 'Additions and deletions' %}: {{ contributor.additions|add:contributor.deletions }} + {% elif contributor.additions|add:contributor.deletions >= 100 %} + {% trans 'Additions and deletions' %}: {{ contributor.additions|add:contributor.deletions }} + {% elif contributor.additions|add:contributor.deletions >= 1 %} + {% trans 'Additions and deletions' %}: {{ contributor.additions|add:contributor.deletions }} + {% endif %} + + From 12aadaeb55d44a5a26cd16cee5a1abc1aa099033 Mon Sep 17 00:00:00 2001 From: Konstantin Freidlin Date: Fri, 2 Sep 2022 19:14:26 +0300 Subject: [PATCH 2/4] Fix locale command (add '--locale' flag) --- Makefile | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Makefile b/Makefile index 90665f65..1e533d19 100644 --- a/Makefile +++ b/Makefile @@ -19,8 +19,8 @@ shell: # Need to have GNU gettext installed transprepare: - @poetry run django-admin makemessages --add-location file - @poetry run django-admin makemessages --add-location file --domain djangojs + @poetry run django-admin makemessages --locale ru --add-location file + @poetry run django-admin makemessages --locale ru --add-location file --domain djangojs transcompile: @poetry run django-admin compilemessages From 0056c1eebc7087256184f1f67135524de628d1e8 Mon Sep 17 00:00:00 2001 From: Konstantin Freidlin Date: Fri, 2 Sep 2022 19:15:03 +0300 Subject: [PATCH 3/4] Update locale for new achievement feature --- locale/ru/LC_MESSAGES/django.mo | Bin 7086 -> 6906 bytes locale/ru/LC_MESSAGES/django.po | 217 ++++++++++++--------- locale/ru/LC_MESSAGES/djangojs.po | 314 +++++++++++++++++++++++++++++- 3 files changed, 436 insertions(+), 95 deletions(-) diff --git a/locale/ru/LC_MESSAGES/django.mo b/locale/ru/LC_MESSAGES/django.mo index 380bdca4d6b7552555cb50288671723811d7650e..937fc373d04d5e81a32df3c482c5159d7e3792aa 100644 GIT binary patch delta 2475 zcmYk-X>1f_9LMpe7xvng-dHRQlv5}-1uC^xt_p|;wBU)`?$B;%x3M%*6|)pf42DEt zkQatnVIMg9JEpBkU^|9qZ#X6CtfdScNZ z3!~Qy)895Em$;8uo@UG*Y#&8N+Lvie7w*R#OwTfgKQo%F49hVC=OK@n#aN2vFC^-t#$2JGk={buHpBLTJGMTP(P)7AsF{|b8md6eYz7wM9DBXY z-fuwuOcR+V(roKHQ3HGp3+dnNrJ$wjL(SwUs>5@rE&1BszlrL27&W82Sb%x7uJ;{O zN7Jp<$Q;Zv)CAWdub4)A9mJ?+)JCBQBRC#+p*naUHNzO{xk1zl4WSyofNJovz5dSL zzm0nTS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y<|w&b&9hZtrZg#p}8+ z>x=I8I_bUBJL4wVaV)1TapF-rYx26I&GGTfV+gX%>gOosP3lK281S5T%I971x;v&1 aj3#Ebc;~3yLw&b--Qkk{1HvN)efu8(@Kt^Q diff --git a/locale/ru/LC_MESSAGES/django.po b/locale/ru/LC_MESSAGES/django.po index b3bf047d..af23e1b6 100644 --- a/locale/ru/LC_MESSAGES/django.po +++ b/locale/ru/LC_MESSAGES/django.po @@ -8,7 +8,7 @@ msgid "" msgstr "" "Project-Id-Version: PACKAGE VERSION\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2020-07-13 16:30+0500\n" +"POT-Creation-Date: 2022-09-02 19:09+0300\n" "PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n" "Last-Translator: FULL NAME \n" "Language-Team: LANGUAGE \n" @@ -57,31 +57,21 @@ msgstr "Неверное имя: " msgid "Uncheck those you wish to skip." msgstr "Снимите выбор тех, что нужно пропустить." -#: contributors/forms/forms.py -msgid "Sort by" -msgstr "Сортировка по" - -#: contributors/forms/forms.py -msgid "Descending" -msgstr "По убыванию" +#: contributors/forms/forms.py templates/contributor_details.html +msgid "Filter by name" +msgstr "Фильтр по имени" #: contributors/forms/forms.py msgid "Search" msgstr "Поиск" -#: contributors/forms/forms.py -msgid "Apply" -msgstr "Применить" - -#: contributors/forms/forms.py -msgid "Reset" -msgstr "Сбросить" - #: contributors/models/base.py msgid "name" msgstr "Имя" #: contributors/models/base.py contributors/models/contribution.py +#: templates/components/tables/contributor_issues.html +#: templates/components/tables/contributor_prs.html msgid "URL" msgstr "" @@ -162,8 +152,8 @@ msgid "title" msgstr "заголовок" #: contributors/models/issue_info.py -msgid "open" -msgstr "открыто" +msgid "state" +msgstr "" #: contributors/models/issue_info.py msgid "issue info" @@ -193,6 +183,10 @@ msgstr "проекты" msgid "full name" msgstr "полное имя" +#: contributors/models/repository.py +msgid "labels" +msgstr "" + #: contributors/models/repository.py msgid "repositories" msgstr "репозитории" @@ -201,12 +195,6 @@ msgstr "репозитории" msgid "Processing configuration" msgstr "Конфигурирование сбора данных" -#: contributors/views/organization.py contributors/views/repositories.py -#: templates/components/tables/repositories_list.html -#: templates/project_details.html templates/repository_details.html -msgid "Project" -msgstr "Проект" - #: contributors/views/organization.py contributors/views/repositories.py #: templates/components/navbar.html #: templates/components/tables/repositories_list.html @@ -221,12 +209,6 @@ msgstr "Контрибьюторы" msgid "Repositories" msgstr "Репозитории" -#: contributors/views/repositories.py -#: templates/components/tables/repositories_list.html -#: templates/repository_details.html -msgid "Organization" -msgstr "Организация" - #: templates/admin/configuration.html msgid "Get repositories" msgstr "Получить репозитории" @@ -276,9 +258,13 @@ msgstr "" msgid "Unknown content" msgstr "" -#: templates/components/footer.html -msgid "Language" -msgstr "Язык" +#: templates/base.html +msgid "" +"A service to track contributions from members of the Hexlet community to the " +"Hexlet open-source projects on GitHub" +msgstr "" +"Сервис для отслеживания вкладов членов сообщества Hexlet в проекты с " +"открытым исходным кодов Hexlet на GitHub" #: templates/components/footer.html msgid "Source code" @@ -320,6 +306,15 @@ msgstr "За всё время" msgid "Open Issues" msgstr "Проблемы" +#: templates/components/navbar.html +#: templates/components/tables/contributors_list.html +#: templates/components/tables/recent_contributors.html +#: templates/components/tables/repositories_list.html +#: templates/contributor_details.html templates/contributor_prs.html +#: templates/projects_list.html templates/pull_requests_list.html +msgid "Pull requests" +msgstr "Запросы на включение" + #: templates/components/navbar.html msgid "Admin" msgstr "Администрирование" @@ -332,9 +327,9 @@ msgstr "Моя статистика" msgid "Log out" msgstr "Выйти" -#: templates/components/navbar.html -msgid "Log in with GitHub" -msgstr "Войти через GitHub" +#: templates/components/navbar.html templates/registration/login.html +msgid "Log in" +msgstr "Войти" #: templates/components/pagination.html msgid "Previous" @@ -344,6 +339,40 @@ msgstr "Назад" msgid "Next" msgstr "Далее" +#: templates/components/tables/contributor_issues.html +#: templates/components/tables/contributor_prs.html +#: templates/components/tables/pull_requests_list.html +msgid "Title" +msgstr "Заголовок" + +#: templates/components/tables/contributor_issues.html +#: templates/components/tables/contributor_prs.html +#: templates/components/tables/pull_requests_list.html +#: templates/contributor_details.html templates/repository_details.html +msgid "Repository" +msgstr "Репозиторий" + +#: templates/components/tables/contributor_issues.html +#: templates/components/tables/contributor_prs.html +#: templates/components/tables/pull_requests_list.html +msgid "Creation date" +msgstr "Дата создания" + +#: templates/components/tables/contributor_issues.html +#: templates/components/tables/contributor_prs.html +#: templates/components/tables/pull_requests_list.html +msgid "Status" +msgstr "Статус" + +#: templates/components/tables/contributor_issues.html +#: templates/components/tables/contributor_prs.html +#: templates/components/tables/contributors_list.html +#: templates/components/tables/organizations_list.html +#: templates/components/tables/pull_requests_list.html +#: templates/components/tables/repositories_list.html +msgid "Nothing found" +msgstr "Ничего не найдено" + #: templates/components/tables/contributors_list.html #: templates/components/tables/recent_contributors.html msgid "Login" @@ -377,14 +406,8 @@ msgstr "Удаления" #: templates/components/tables/contributors_list.html #: templates/components/tables/recent_contributors.html #: templates/components/tables/repositories_list.html -#: templates/contributor_details.html templates/projects_list.html -msgid "Pull requests" -msgstr "Запросы на включение" - -#: templates/components/tables/contributors_list.html -#: templates/components/tables/recent_contributors.html -#: templates/components/tables/repositories_list.html -#: templates/contributor_details.html templates/projects_list.html +#: templates/contributor_details.html templates/contributor_issues.html +#: templates/projects_list.html msgid "Issues" msgstr "Проблемы" @@ -394,11 +417,19 @@ msgstr "Проблемы" msgid "Comments" msgstr "Комментарии" -#: templates/components/tables/contributors_list.html -#: templates/components/tables/organizations_list.html +#: templates/components/tables/pull_requests_list.html +msgid "Author" +msgstr "Автор" + #: templates/components/tables/repositories_list.html -msgid "Nothing found" -msgstr "Ничего не найдено" +#: templates/repository_details.html +msgid "Organization" +msgstr "Организация" + +#: templates/components/tables/repositories_list.html +#: templates/project_details.html templates/repository_details.html +msgid "Project" +msgstr "Проект" #: templates/components/time_note.html msgid "since" @@ -408,6 +439,28 @@ msgstr "с" msgid "for the past month" msgstr "за прошедший месяц" +#: templates/contributor_details.html +msgid "Contributor" +msgstr "Участник" + +#: templates/contributor_details.html +msgid "Achievments" +msgstr "Достижения" + +#: templates/contributor_details.html +msgid "Hexlet friend" +msgstr "Друг Хекслета" + +#: templates/contributor_details.html +#, fuzzy +#| msgid "Issues" +msgid "Issuess" +msgstr "Проблемы" + +#: templates/contributor_details.html +msgid "Additions and deletions" +msgstr "Добавления и удаления" + #: templates/contributor_details.html templates/home.html msgid "Past year activity" msgstr "Активность за год" @@ -416,14 +469,13 @@ msgstr "Активность за год" msgid "All-time contributions" msgstr "Вклад за всё время" -#: templates/contributor_details.html -msgid "Filter by name" -msgstr "Фильтр по имени" +#: templates/contributor_issues.html +msgid "Issues by" +msgstr "Issues пользователя" -#: templates/contributor_details.html -#: templates/components/pull_requests_list.html -msgid "Repository" -msgstr "Репозиторий" +#: templates/contributor_prs.html +msgid "Pull requests by" +msgstr "Пулл реквесты пользователя" #: templates/contributors_for_month.html msgid "Contributors for month" @@ -453,6 +505,10 @@ msgstr "по комментариям" msgid "New PRs and issues" msgstr "Новые PR и проблемы" +#: templates/organization_details.html +msgid "Details for organization" +msgstr "Детали организации" + #: templates/project_details.html msgid "Project related repositories" msgstr "Связанные с проектом репозитории" @@ -462,10 +518,6 @@ msgctxt "logon" msgid "Login" msgstr "Вход" -#: templates/registration/login.html -msgid "Log in" -msgstr "Войти" - #: templates/registration/registration.html msgid "Registration" msgstr "Регистрация" @@ -474,41 +526,26 @@ msgstr "Регистрация" msgid "Register" msgstr "Зарегистрироваться" -#~ msgid "Recently active contributors" -#~ msgstr "Недавно активные участники" +#~ msgid "Sort by" +#~ msgstr "Сортировка по" -#: templates/base.html -msgid "A service to track contributions from members of the Hexlet community to the Hexlet open-source projects on GitHub" -msgstr "Сервис для отслеживания вкладов членов сообщества Hexlet в проекты с открытым исходным кодов Hexlet на GitHub" - -#: templates/contributor_details.html -msgid "Contributor" -msgstr "Участник" - -#: templates/contributor_issues.html -msgid "Issues by" -msgstr "Issues пользователя" +#~ msgid "Descending" +#~ msgstr "По убыванию" -#: templates/contributor_prs.html -msgid "Pull requests by" -msgstr "Пулл реквесты пользователя" +#~ msgid "Apply" +#~ msgstr "Применить" -#: templates/organization_details.html -msgid "Details for organization" -msgstr "Детали организации" +#~ msgid "Reset" +#~ msgstr "Сбросить" -#: templates/components/pull_requests_list.html -msgid "Author" -msgstr "Автор" +#~ msgid "open" +#~ msgstr "открыто" -#: templates/components/pull_requests_list.html -msgid "Status" -msgstr "Статус" +#~ msgid "Language" +#~ msgstr "Язык" -#: templates/components/pull_requests_list.html -msgid "Creation date" -msgstr "Дата создания" +#~ msgid "Log in with GitHub" +#~ msgstr "Войти через GitHub" -#: templates/components/pull_requests_list.html -msgid "Title" -msgstr "Заголовок" +#~ msgid "Recently active contributors" +#~ msgstr "Недавно активные участники" diff --git a/locale/ru/LC_MESSAGES/djangojs.po b/locale/ru/LC_MESSAGES/djangojs.po index 57c83a57..ee2629ea 100644 --- a/locale/ru/LC_MESSAGES/djangojs.po +++ b/locale/ru/LC_MESSAGES/djangojs.po @@ -8,7 +8,7 @@ msgid "" msgstr "" "Project-Id-Version: PACKAGE VERSION\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2020-04-21 15:28+0500\n" +"POT-Creation-Date: 2022-09-02 19:09+0300\n" "PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n" "Last-Translator: FULL NAME \n" "Language-Team: LANGUAGE \n" @@ -20,18 +20,322 @@ msgstr "" "%10<=4 && (n%100<12 || n%100>14) ? 1 : n%10==0 || (n%10>=5 && n%10<=9) || (n" "%100>=11 && n%100<=14)? 2 : 3);\n" -#: static/js/activity_chart/chart.js +#: static/js/activity_chart/chart.js staticfiles/js/activity_chart/chart.js msgid "Commits" msgstr "Коммиты" -#: static/js/activity_chart/chart.js +#: static/js/activity_chart/chart.js staticfiles/js/activity_chart/chart.js msgid "Pull requests" msgstr "Запросы на включение" -#: static/js/activity_chart/chart.js +#: static/js/activity_chart/chart.js staticfiles/js/activity_chart/chart.js msgid "Issues" msgstr "Проблемы" -#: static/js/activity_chart/chart.js +#: static/js/activity_chart/chart.js staticfiles/js/activity_chart/chart.js msgid "Comments" msgstr "Комментарии" + +#: staticfiles/admin/js/SelectFilter2.js +#, javascript-format +msgid "Available %s" +msgstr "" + +#: staticfiles/admin/js/SelectFilter2.js +#, javascript-format +msgid "" +"This is the list of available %s. You may choose some by selecting them in " +"the box below and then clicking the \"Choose\" arrow between the two boxes." +msgstr "" + +#: staticfiles/admin/js/SelectFilter2.js +#, javascript-format +msgid "Type into this box to filter down the list of available %s." +msgstr "" + +#: staticfiles/admin/js/SelectFilter2.js +msgid "Filter" +msgstr "" + +#: staticfiles/admin/js/SelectFilter2.js +msgid "Choose all" +msgstr "" + +#: staticfiles/admin/js/SelectFilter2.js +#, javascript-format +msgid "Click to choose all %s at once." +msgstr "" + +#: staticfiles/admin/js/SelectFilter2.js +msgid "Choose" +msgstr "" + +#: staticfiles/admin/js/SelectFilter2.js +msgid "Remove" +msgstr "" + +#: staticfiles/admin/js/SelectFilter2.js +#, javascript-format +msgid "Chosen %s" +msgstr "" + +#: staticfiles/admin/js/SelectFilter2.js +#, javascript-format +msgid "" +"This is the list of chosen %s. You may remove some by selecting them in the " +"box below and then clicking the \"Remove\" arrow between the two boxes." +msgstr "" + +#: staticfiles/admin/js/SelectFilter2.js +msgid "Remove all" +msgstr "" + +#: staticfiles/admin/js/SelectFilter2.js +#, javascript-format +msgid "Click to remove all chosen %s at once." +msgstr "" + +#: staticfiles/admin/js/actions.js +msgid "%(sel)s of %(cnt)s selected" +msgid_plural "%(sel)s of %(cnt)s selected" +msgstr[0] "" +msgstr[1] "" +msgstr[2] "" +msgstr[3] "" + +#: staticfiles/admin/js/actions.js +msgid "" +"You have unsaved changes on individual editable fields. If you run an " +"action, your unsaved changes will be lost." +msgstr "" + +#: staticfiles/admin/js/actions.js +msgid "" +"You have selected an action, but you haven’t saved your changes to " +"individual fields yet. Please click OK to save. You’ll need to re-run the " +"action." +msgstr "" + +#: staticfiles/admin/js/actions.js +msgid "" +"You have selected an action, and you haven’t made any changes on individual " +"fields. You’re probably looking for the Go button rather than the Save " +"button." +msgstr "" + +#: staticfiles/admin/js/admin/DateTimeShortcuts.js +msgid "Now" +msgstr "" + +#: staticfiles/admin/js/admin/DateTimeShortcuts.js +msgid "Midnight" +msgstr "" + +#: staticfiles/admin/js/admin/DateTimeShortcuts.js +msgid "6 a.m." +msgstr "" + +#: staticfiles/admin/js/admin/DateTimeShortcuts.js +msgid "Noon" +msgstr "" + +#: staticfiles/admin/js/admin/DateTimeShortcuts.js +msgid "6 p.m." +msgstr "" + +#: staticfiles/admin/js/admin/DateTimeShortcuts.js +#, javascript-format +msgid "Note: You are %s hour ahead of server time." +msgid_plural "Note: You are %s hours ahead of server time." +msgstr[0] "" +msgstr[1] "" +msgstr[2] "" +msgstr[3] "" + +#: staticfiles/admin/js/admin/DateTimeShortcuts.js +#, javascript-format +msgid "Note: You are %s hour behind server time." +msgid_plural "Note: You are %s hours behind server time." +msgstr[0] "" +msgstr[1] "" +msgstr[2] "" +msgstr[3] "" + +#: staticfiles/admin/js/admin/DateTimeShortcuts.js +msgid "Choose a Time" +msgstr "" + +#: staticfiles/admin/js/admin/DateTimeShortcuts.js +msgid "Choose a time" +msgstr "" + +#: staticfiles/admin/js/admin/DateTimeShortcuts.js +msgid "Cancel" +msgstr "" + +#: staticfiles/admin/js/admin/DateTimeShortcuts.js +msgid "Today" +msgstr "" + +#: staticfiles/admin/js/admin/DateTimeShortcuts.js +msgid "Choose a Date" +msgstr "" + +#: staticfiles/admin/js/admin/DateTimeShortcuts.js +msgid "Yesterday" +msgstr "" + +#: staticfiles/admin/js/admin/DateTimeShortcuts.js +msgid "Tomorrow" +msgstr "" + +#: staticfiles/admin/js/calendar.js +msgid "January" +msgstr "" + +#: staticfiles/admin/js/calendar.js +msgid "February" +msgstr "" + +#: staticfiles/admin/js/calendar.js +msgid "March" +msgstr "" + +#: staticfiles/admin/js/calendar.js +msgid "April" +msgstr "" + +#: staticfiles/admin/js/calendar.js +msgid "May" +msgstr "" + +#: staticfiles/admin/js/calendar.js +msgid "June" +msgstr "" + +#: staticfiles/admin/js/calendar.js +msgid "July" +msgstr "" + +#: staticfiles/admin/js/calendar.js +msgid "August" +msgstr "" + +#: staticfiles/admin/js/calendar.js +msgid "September" +msgstr "" + +#: staticfiles/admin/js/calendar.js +msgid "October" +msgstr "" + +#: staticfiles/admin/js/calendar.js +msgid "November" +msgstr "" + +#: staticfiles/admin/js/calendar.js +msgid "December" +msgstr "" + +#: staticfiles/admin/js/calendar.js +msgctxt "abbrev. month January" +msgid "Jan" +msgstr "" + +#: staticfiles/admin/js/calendar.js +msgctxt "abbrev. month February" +msgid "Feb" +msgstr "" + +#: staticfiles/admin/js/calendar.js +msgctxt "abbrev. month March" +msgid "Mar" +msgstr "" + +#: staticfiles/admin/js/calendar.js +msgctxt "abbrev. month April" +msgid "Apr" +msgstr "" + +#: staticfiles/admin/js/calendar.js +msgctxt "abbrev. month May" +msgid "May" +msgstr "" + +#: staticfiles/admin/js/calendar.js +msgctxt "abbrev. month June" +msgid "Jun" +msgstr "" + +#: staticfiles/admin/js/calendar.js +msgctxt "abbrev. month July" +msgid "Jul" +msgstr "" + +#: staticfiles/admin/js/calendar.js +msgctxt "abbrev. month August" +msgid "Aug" +msgstr "" + +#: staticfiles/admin/js/calendar.js +msgctxt "abbrev. month September" +msgid "Sep" +msgstr "" + +#: staticfiles/admin/js/calendar.js +msgctxt "abbrev. month October" +msgid "Oct" +msgstr "" + +#: staticfiles/admin/js/calendar.js +msgctxt "abbrev. month November" +msgid "Nov" +msgstr "" + +#: staticfiles/admin/js/calendar.js +msgctxt "abbrev. month December" +msgid "Dec" +msgstr "" + +#: staticfiles/admin/js/calendar.js +msgctxt "one letter Sunday" +msgid "S" +msgstr "" + +#: staticfiles/admin/js/calendar.js +msgctxt "one letter Monday" +msgid "M" +msgstr "" + +#: staticfiles/admin/js/calendar.js +msgctxt "one letter Tuesday" +msgid "T" +msgstr "" + +#: staticfiles/admin/js/calendar.js +msgctxt "one letter Wednesday" +msgid "W" +msgstr "" + +#: staticfiles/admin/js/calendar.js +msgctxt "one letter Thursday" +msgid "T" +msgstr "" + +#: staticfiles/admin/js/calendar.js +msgctxt "one letter Friday" +msgid "F" +msgstr "" + +#: staticfiles/admin/js/calendar.js +msgctxt "one letter Saturday" +msgid "S" +msgstr "" + +#: staticfiles/admin/js/collapse.js +msgid "Show" +msgstr "" + +#: staticfiles/admin/js/collapse.js +msgid "Hide" +msgstr "" From 78643bdf99e8cef755b54115de56e1907f519cdd Mon Sep 17 00:00:00 2001 From: Konstantin Freidlin Date: Fri, 2 Sep 2022 19:15:16 +0300 Subject: [PATCH 4/4] Add editor config --- .editorconfig | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) create mode 100644 .editorconfig diff --git a/.editorconfig b/.editorconfig new file mode 100644 index 00000000..b439e23f --- /dev/null +++ b/.editorconfig @@ -0,0 +1,18 @@ +[Makefile] +indent_style = tab + +[*.html] +indent_style = space +indent_size = 2 + +[*.js] +indent_style = space +indent_size = 2 + +[*.css] +indent_style = space +indent_size = 2 + +[*.py] +indent_style = space +indent_size = 4