WebarchivCZ / Seeder

Seeder - Czech webarchive curating tool and public site
MIT License
15 stars 2 forks source link

transifex #419

Closed westfood closed 7 years ago

westfood commented 7 years ago

Tohle je cajk?

pull

(seeder) [rudolf@war Seeder]$ tx pull -a
New translations found for the following languages:en, en_GB
Pulling translations for resource seeder-production.djangopo (source: locale/en/LC_MESSAGES/django.po)
Skipping 'en_US' translation (file: locale/en_US/LC_MESSAGES/django.po).
Skipping 'cs' translation (file: locale/cs/LC_MESSAGES/django.po).
Pulling new translations for resource seeder-production.djangopo (source: locale/en/LC_MESSAGES/django.po)
 -> en: locale/en/LC_MESSAGES/django.po
 -> en_GB: locale/en_GB/LC_MESSAGES/django.po
Done.

push

(seeder) [rudolf@war Seeder]$ tx push -t -s
Pushing translations for resource seeder-production.djangopo:
Pushing source file (locale/en/LC_MESSAGES/django.po)
Exception: Only maintainers are allowed to update the source file.

conf

(seeder) [rudolf@war Seeder]$ cat .transifexrc
[https://www.transifex.com]
hostname = https://www.transifex.com
password = <CENZORED>
token =
username = westfood@gmail.com
Visgean commented 7 years ago

sorry, to je nejaka novinka na jejich strane, pridal jsem te do seznamu.

westfood commented 7 years ago

díkes

westfood commented 7 years ago

Hele, stále not cajk.

Pushing source file (locale/en/LC_MESSAGES/django.po) ` includes an empty msgstr. Provide a value and try again.

(seeder) [rudolf@war Seeder]$ tx pull -a
New translations found for the following languages:en
Pulling translations for resource seeder-production.djangopo (source: locale/en/LC_MESSAGES/django.po)
Skipping 'cs' translation (file: locale/cs/LC_MESSAGES/django.po).
Skipping 'en_US' translation (file: locale/en_US/LC_MESSAGES/django.po).
Skipping 'en_GB' translation (file: locale/en_GB/LC_MESSAGES/django.po).
Pulling new translations for resource seeder-production.djangopo (source: locale/en/LC_MESSAGES/django.po)
 -> en: locale/en/LC_MESSAGES/django.po
Done.
(seeder) [rudolf@war Seeder]$ tx push -t -s
Pushing translations for resource seeder-production.djangopo:
Pushing source file (locale/en/LC_MESSAGES/django.po)
        ` includes an empty msgstr. Provide a value and try again.
(seeder) [rudolf@war Seeder]$ cat .transifexrc
[https://www.transifex.com]
hostname = https://www.transifex.com
password = <CENSORED>
token =
username = westfood@gmail.com
Visgean commented 7 years ago

locale.tar.gz

nakopiruj si moje locale, pak by to melo fungovat

westfood commented 7 years ago

hele to asi jo, spíš je teda otázka, proč je to na serveru vygenerovaný jinak ne? Jde mi o to, abychom se do stejné situace nedostali dvakrát.

Visgean commented 7 years ago

something something ubuntu something something redhat python... Dvakrat uz se do toho nedostaneme, idealne budu pushovat nove soubory k prekladu pouze ja

westfood commented 7 years ago

hele, jde o to, že když smažu locales, tak tx pull by měl stáhnout překladový soubory v cajku ne?

Visgean commented 7 years ago

ano, to se nedeje?

westfood commented 7 years ago

vypadá že ne

(seeder) [rudolf@war Seeder]$ rm -r locale/*
(seeder) [rudolf@war Seeder]$ tx pull -a
New translations found for the following languages:cs, en, en_US, en_GB
Pulling new translations for resource seeder-production.djangopo (source: locale/en/LC_MESSAGES/django.po)
 -> cs: locale/cs/LC_MESSAGES/django.po
 -> en: locale/en/LC_MESSAGES/django.po
 -> en_US: locale/en_US/LC_MESSAGES/django.po
 -> en_GB: locale/en_GB/LC_MESSAGES/django.po
Done.
(seeder) [rudolf@war Seeder]$ ./manage.py compilemessages
processing file django.po in /mnt/raid1/git/Seeder/Seeder/locale/en_US/LC_MESSAGES
processing file django.po in /mnt/raid1/git/Seeder/Seeder/locale/en/LC_MESSAGES
processing file django.po in /mnt/raid1/git/Seeder/Seeder/locale/en_GB/LC_MESSAGES
processing file django.po in /mnt/raid1/git/Seeder/Seeder/locale/cs/LC_MESSAGES
(seeder) [rudolf@war Seeder]$ ./manage.py makemessages -a
processing locale cs
processing locale en
processing locale en_US
processing locale en_GB
(seeder) [rudolf@war Seeder]$ tx push -t -s
Pushing translations for resource seeder-production.djangopo:
Pushing source file (locale/en/LC_MESSAGES/django.po)
        ` includes an empty msgstr. Provide a value and try again.
Visgean commented 7 years ago

muzes checknout jestli se ty preklady stahli spravne? staci otevrit ty po soubory

westfood commented 7 years ago

řekl bych že cajk. screenshot 2017-07-18 16 01 36

westfood commented 7 years ago

našel jsem v překladu tenhle řádek, ale imho snad neměl dělat problém:

msgstr "{0} - {1}"

a ty prázdný imho taky ne:

msgstr ""
westfood commented 7 years ago

ale je tam třeba:

#: voting/templates/voting_round.html:25
#, python-format
msgid ""
"\n"
"            <p>\n"
"                <b>%(source)s</b> was added to system\n"
"                <b>%(source_created)s</b>. This voting round determines\n"
"                whether %(source)s will be archived\n"
"                or die in the shadows of unarchived internet.\n"
"            </p>\n"
"        "
msgstr ""

#: voting/templates/voting_round.html:34
#, python-format
msgid ""
"\n"
"                <p>\n"
"                    This voting round opened <b>%(round_created)s</b>.\n"
"                    Remember you have the power to change how future\n"
"                    generations remember us. Cast a vote!\n"
"                </p>\n"
"            "
msgstr ""
Visgean commented 7 years ago

Hele to vypada, ze je tok

westfood commented 7 years ago

Koukni sám locale.tar.gz

westfood commented 7 years ago

Ale tohle si pullne sám transifex, tak by to mělo být cajk.

Visgean commented 7 years ago

Ja myslim, ze je tok.

westfood commented 7 years ago

A tušíš co s tím?

Visgean commented 7 years ago

Pockej a jaky je problem ted?

On Tue, 25 Jul 2017, 15:02 Rudolf, notifications@github.com wrote:

A tušíš co s tím?

— You are receiving this because you modified the open/close state.

Reply to this email directly, view it on GitHub https://github.com/WebarchivCZ/Seeder/issues/419#issuecomment-317730156, or mute the thread https://github.com/notifications/unsubscribe-auth/AAL1KBL9P7pS2vUsB2tAbu6gEH2U1vyBks5sRedjgaJpZM4OXKbe .

westfood commented 7 years ago

furt tenhle:

(seeder) [rudolf@war Seeder]$ tx push -t -s
Pushing translations for resource seeder-production.djangopo:
Pushing source file (locale/en/LC_MESSAGES/django.po)
        ` includes an empty msgstr. Provide a value and try again.
Visgean commented 7 years ago

ok, tak jsem to protestoval do sedmeho kolene, nasel jsem nejake chyby v predkladech ktere zpusobovali, ze neslo kompilovat. Ty jsem opravil.

Smazal jsem si svoje locales a zkusil pullnout ciste z transifexu a dostal jsem se do stejnych problemu jako ty. Vzhledem k tomu, ze jsou to ciste verze tak nechapu kde je problem. Pridal jsem soubory .po soubory do gitu. Myslim, ze uz by zmen melo byt minimalne a je lepsi to udrzovat v gitu kde nad tim je kontrola a transparentnost.

Pouzivejme tedy na preklady https://poedit.net/download a vse mejme v gitu. @kvasnicaj

westfood commented 7 years ago

Čéšť, jeden trabl s tímle přístupem..

když poprvé nahodím Seeder z repozitáře, pustím ./manage.py "compilemessages", "makemessages -a" tak se mi rozhodí lokální repozitář a původní na githubu:

-bash-4.2$ git status
# On branch master
# Changes not staged for commit:
#   (use "git add <file>..." to update what will be committed)
#   (use "git checkout -- <file>..." to discard changes in working directory)
#
#       modified:   Seeder/locale/cs/LC_MESSAGES/django.po
#       modified:   Seeder/locale/en/LC_MESSAGES/django.po
#       modified:   Seeder/locale/en_GB/LC_MESSAGES/django.po
#       modified:   Seeder/locale/en_US/LC_MESSAGES/django.po

Ty změny např..

diff --git a/Seeder/locale/cs/LC_MESSAGES/django.po b/Seeder/locale/cs/LC_MESSAGES/django.po
index 0e498fc..ca7c6f0 100644
--- a/Seeder/locale/cs/LC_MESSAGES/django.po
+++ b/Seeder/locale/cs/LC_MESSAGES/django.po
@@ -1,7 +1,7 @@
 # SOME DESCRIPTIVE TITLE.
 # Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER
 # This file is distributed under the same license as the PACKAGE package.
-#
+#
 # Translators:
 # Visgean Skeloru <visgean@gmail.com>, 2017
 # mariehaskovcova <marie.haskovcova@nkp.cz>, 2017
@@ -9,14 +9,15 @@ msgid ""
 msgstr ""
 "Project-Id-Version: Seeder\n"
 "Report-Msgid-Bugs-To: \n"
-"POT-Creation-Date: 2017-07-03 12:06+0000\n"
+"POT-Creation-Date: 2017-07-30 16:09+0000\n"
 "PO-Revision-Date: 2017-06-27 00:16+0000\n"
 "Last-Translator: mariehaskovcova <marie.haskovcova@nkp.cz>, 2017\n"
-"Language-Team: Czech (https://www.transifex.com/webarchivecz/teams/43032/cs/)\n"
+"Language-Team: Czech (https://www.transifex.com/webarchivecz/teams/43032/"
+"cs/)\n"
+"Language: cs\n"
 "MIME-Version: 1.0\n"
 "Content-Type: text/plain; charset=UTF-8\n"
 "Content-Transfer-Encoding: 8bit\n"
-"Language: cs\n"
 "Plural-Forms: nplurals=3; plural=(n==1) ? 0 : (n>=2 && n<=4) ? 1 : 2;\n"

 #: blacklists/models.py:22
@@ -246,12 +247,10 @@ msgid "Description"
 msgstr "Popis"
Visgean commented 7 years ago

Nerozhodi. Makemessages by jsi mel poustet v pripade, ze se zmeni neco v projektu.

westfood commented 7 years ago

Hele, já myslel že všechny manage.py příkazy budou idempotentní.

Co znamená změna projektu? Můžu si to automatizace nějak dobře zjistit?

Visgean commented 7 years ago

Zrovna tenhle neni, uz jenom proto ze vzdy aktualizuje datum. Tenhle prikaz proste hleda vsechny prekladatelne retezce a na zaklade nich vygeneruje ten po soubor. Mel bych ho spoustet jenom ja, abych vam vygeneroval retezce k prekladu, vy si pak jenom zeditujete po soubor a ten commitnete...

kvasnicaj commented 7 years ago

poedit za mě vypadá v pohodě a myslím, že je to lepší přes ty commity na GITu 👍

kvasnicaj commented 7 years ago

@Visgean můžu tě poprosit, jestli bys mohl uklidit ten bordel v locale, aby tam zbyly jen dva .po soubory. Jeden zdrojový pro angličtinu a češtinu? Teď je jich tam nějak víc, asi to tam nasekal ještě Transifex

Visgean commented 7 years ago

ok, done.

westfood commented 7 years ago

OK, takže ./manage.py "compilemessages", "makemessages budeš pouštět ty, nebo já na základě nějakých podmínek?

Visgean commented 7 years ago

ja to pak hodim do readme.

westfood commented 7 years ago

Testnu a dám vědět..

Visgean commented 7 years ago

Asi muzu zavrit, ne?

westfood commented 7 years ago

jo, nepouštím: "makemessages -a" je to v cajku