liberapay / salon

Liberapay's salon, where the discussions that don't belong elsewhere take place
22 stars 3 forks source link

Move existing translation from "pt" to "pt-br" and delete 1 component #469

Open laralem opened 2 years ago

laralem commented 2 years ago

Hi, I was correcting and translating some new strings in Weblate when I noticed a problem. In "Core" component the current translation in "pt" Portuguese (https://hosted.weblate.org/projects/liberapay/core/pt/) is in the variant "pt-br" Brazilian Portuguese. I could request the creation of "pt-br" and then download from "pt" and upload the translation to "pt-br", but this process does not copy the history and the authors, besides that I have made some translations and I will have to revert them (less than 100) because I thought there was an "pt-br" version and someone from Brazil made a mistake translating "pt" version (is a bit common).

Also the "pt-pt" version of the "Liberapay Everywhere" component (https://hosted.weblate.org/projects/liberapay/liberapay-everywhere/pt_PT/) should be deleted. The "pt" translation is the right one for Portugal and other Portuguese speaking countries except Brazil which already has the respective translation. This translation is redundant unless there is a technical reason for it to exist.

jorgesumle commented 2 years ago

The pt code (the one we use now) doesn't refer to any specific variant of Portuguese, but it is meant for generic Portuguese, not for Portuguese of Portugal, which is pt_PT. I know there is no such thing as an international Portuguese or standard Portuguese (in any case, there are two main standards: European Portuguese, with code pt_PT, and Brazilian Portuguese, with code pt_BR). pt just is how the Common Locale Data Repository refers to Portuguese without specifying any variant.

We could create a pt_PT translation from the existing pt, and you can modify it, so that it is Portuguese from Portugal (are you from Portugal or am I guessing wrong?). Then we could rename the current generic pt to pt_BR, so that we have the both most important Portuguese variants. If you need help, I'm here to help you out.

this process does not copy the history and the authors,

Don't worry about that, the history is already on Git. This is the list of people who modified that file, and we have the changes they made on Git (git shortlog -n -s -- i18n/core/pt.po):

pt.po
   450  Changaco
    53  Paulo Santos
    17  anonymous
    16  Chad Whitacre
    12  ssantos
     6  Daniele Lira Mereb
     4  D.W. Sage
     4  Luke Strickland
     3  Rute
     2  Fábio Rosado
     2  Jorge Maldonado Ventura
     2  Louis Rannou
     2  Rafael Humberto de Lima Moretti
     2  aevw
     2  hugoroger
     1  ASKvast.org
     1  Breno Silva
     1  Ingo Blechschmidt
     1  Marcelle Cristina
     1  Matheus do Nascimento
     1  Michal Čihař
     1  Peter J. Mello
     1  Rafael Fontenelle
     1  Rafael Reinehr
     1  Rui Mendes
     1  Sean Linsley
     1  Vinicius Dias
     1  Waldir Pimenta
     1  sb

By the way, the Spanish translation is also just es, and it is Spanish from Spain, so I guess the country code ISO 3166 ES would have to be added when someone submits a different Spanish variant.

This translation is redundant unless there is a technical reason for it to exist.

Maybe, but there are other Portuguese speaking countries apart from Brazil and Portugal. I wouldn't remove it, as it doesn't hurt to have it. As a translator, you should only focus on the variant of the country where you live.

laralem commented 2 years ago

Correct, I'm from Portugal. I want to edit the generic version pt which is simply called "Portuguese", applicable to all countries: Portugal, Angola, Cape Verde, Guinea-Bissau, Equatorial Guinea, Mozambique, São Tomé and Príncipe and Timor-Leste, except Brazil. It makes no sense to create a version for Portugal, another for Angola, another for Mozambique... except for Brazil.

I have done many translations and normally, in the software context, only 2 versions of Portuguese are created, Portuguese pt and Brazilian Portuguese pt-br.

The best solution is really rename pt to pt_BR so I can edit the pt.

jorgesumle commented 2 years ago

I want to edit the generic version pt

The most "generic" variant might be Brazilian Portuguese. According to Wikipedia, 72,5% of Portuguese speakers are from Brazil, more than the other Portuguese-speaking countries combined.

It makes no sense to create a version for Portugal, another for Angola, another for Mozambique... except for Brazil.

I'm not saying we should do that. I think it's enough to have the two main Portuguese dialects, unless someone from that country would like to create a translation for their dialect (even if it isn't very different from the European Portuguese).

I have done many translations and normally, in the software context, only 2 versions of Portuguese are created, Portuguese pt and Brazilian Portuguese pt-br.

In the translation project of getgnulinux.org, for example, there are just two versions: one from Brazil (pt-BR) and other for Portugal (pt-PT). Another example is Firefox, https://www.mozilla.org/pt/firefox/new/ redirects to https://www.mozilla.org/pt-BR/firefox/new/, not to https://www.mozilla.org/pt-PT/firefox/new/, so they treat pt-BR as the most generic. It's difficult to know what most people do, but maybe you're right. However, I would rather decide based on reasons.

In my opinion, it's better to be less ambiguous, and specify both pt-BR and pt-PT. What we do with the existing https://pt.liberapay.com/ URL is another question. I vote for doing what Firefox does, pt redirects to the most spoken variant pt_BR, unless the user has the browser configured to prefer European Portuguese. Also, for new translators it's better if they see something like "Português (Portugal)" in Weblate. If we don't specify anything, people might think that anything goes, and someone might translate using Brazilian Portuguese again. This way there is no ambiguity.

The best solution is really rename pt to pt_BR so I can edit the pt.

Did I change your mind?

Changaco commented 2 years ago

Having separate translations for variants of the same language still isn't implemented. See https://github.com/liberapay/liberapay.com/issues/1073 for details.