WhereYouGo icon indicating copy to clipboard operation
WhereYouGo copied to clipboard

Rename language pt_PT to pt

Open bekuno opened this issue 3 years ago • 8 comments

Tell us your idea!

The language resolution strategy of android is described in https://developer.android.com/guide/topics/resources/multilingual-support#preN . If we rename pt_PT to pt, then a system language configuration of pt_PT is mapped to pt, and a system language of pt is resolved directly.

@Lineflyer We have a simular solution for zh_CN in c:geo.

What solution would you suggest?

No response

Is there an alternative?

No response

Additional Information

No response

bekuno avatar Jan 03 '22 20:01 bekuno

Its a language code mapping on Crowdin. I could set this up easily, but what to do with brazilian then?

image

Lineflyer avatar Jan 03 '22 21:01 Lineflyer

For comparison, that is what we use for c:geo: image

Lineflyer avatar Jan 03 '22 21:01 Lineflyer

Please look at Chinese Simplified (zh_CN). How is Portuguese defined for c:geo?

Btw., I can´t found/see this mapping. Is it here on the Github integrations page? (https://crowdin.com/project/whereyougo/apps/system/github) grafik

The pt_BR should stay unchanged, like zh_TW for c:geo. See also https://github.com/cgeo/cgeo/blob/master/main/build.gradle#L54

bekuno avatar Jan 03 '22 22:01 bekuno

Its not bound to Github integration but a generic setting for the Crowdin project, you can find it in the settings in the section "export" behind "language mapping": image

Lineflyer avatar Jan 03 '22 22:01 Lineflyer

The pt_BR should stay unchanged, like zh_TW for c:geo.

That would mean I simply remove the pt to pr_rPT mapping then. However there was a reason I did that...need to look through old issues first...I wouldn't have done it without need.

Lineflyer avatar Jan 03 '22 22:01 Lineflyer

In https://github.com/cgeo/WhereYouGo/issues/23#issuecomment-610352494 I noted down, that without this rPT theere is something missing from Crowdin....but we can try what happens.

Not sure if it will work as I also mention in that thread, that the change needs to be done before creating the integration to Github.

I will try that out as time permits, but can we stay with the hotfix provided until then or is it mandatory to change this before we can merge that PR?

Lineflyer avatar Jan 03 '22 22:01 Lineflyer

Ok, found it. The Chinese Simplified is mapping to the default 2-letter code.

I will try that out as time permits, but can we stay with the hotfix provided until then or is it mandatory to change this before we can merge that PR?

The PR is fine in the current implementation with a workaround for Portuguese pt. After the change at crowdin this workaround should be removed.

bekuno avatar Jan 03 '22 23:01 bekuno

In #23 (comment) I noted down, that without this rPT theere is something missing from Crowdin....but we can try what happens.

After reading the comment, I think we first need to rename the folder values-pt-rPT to values-pt . Then remove the special mapping at crowdin.

bekuno avatar Jan 03 '22 23:01 bekuno