Skip to content

Locales: Fix placeholder inconsistencies #25291

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
wants to merge 4 commits into from
Closed

Locales: Fix placeholder inconsistencies #25291

wants to merge 4 commits into from

Conversation

fnetX
Copy link
Contributor

@fnetX fnetX commented Jun 15, 2023

Address #25238

This fixes all placeholder inconsistencies in translations that I have found, some of them probably don't change anything visible, but they're inconsistent nevertheless.

I do not know how RTL text and placeholders work together, so these strings are left to check:

options/locale/locale_tr-TR.ini check how rtl and strings correlate
options/locale/locale_fa-IR.ini:delete_tag=برچسب %[2] از <a href="%[1]s">%[3]</a> حذف شدند
options/locale/locale_fa-IR.ini:delete_branch=شاخه %[2] از <a href="%[1]s">%[3]</a> حذف شدند
options/locale/locale_fa-IR.ini:issues.ref_reopening_from=`<a href="%[3]s"> تقاضای واکشی ارجاع شده %[4] که مسائله بازگشایی خواهد کرد</a> <a id="%[1]s" href="#%[1]s">%[2] </a>`
options/locale/locale_fa-IR.ini:issues.ref_from=`از %[1]`
options/locale/locale_fa-IR.ini:monitor.queue.settings.maxnumberworkers.placeholder=در حال حاضر %[1]v
options/locale/locale_fa-IR.ini:issue_assigned.pull=@%[1]s به شما برای درخواست pull %[2]s در ریپازیتوری %[3] محول شده.
options/locale/locale_fa-IR.ini:delete_tag=برچسب %[2] از <a href="%[1]s">%[3]</a> حذف شدند
options/locale/locale_fa-IR.ini:delete_branch=شاخه %[2] از <a href="%[1]s">%[3]</a> حذف شدند
options/locale/locale_fa-IR.ini:issues.ref_issue_from=`<a href="%[3]s"> ارجاعات این مسائله %[4]</a> <a id="%[1]s" href="#%[1]s">%[2]s</a>`
options/locale/locale_fa-IR.ini:issues.ref_pull_from=`<a href="%[3]s"> ارجاعات این تقاضای ادغام %[4]</a> <a id="%[1]s" href="#%[1]s">%[2]s</a>`
options/locale/locale_fa-IR.ini:issues.ref_closing_from=`<a href="%[3]s"> ارجاعات این تقاضای واکشی %[4]</a> <a id="%[1]s" href="#%[1]s">%[2]s</a>`
options/locale/locale_fa-IR.ini:issues.ref_reopening_from=`<a href="%[3]s"> تقاضای واکشی ارجاع شده %[4] که مسائله بازگشایی خواهد کرد</a> <a id="%[1]s" href="#%[1]s">%[2] </a>`
options/locale/locale_fa-IR.ini:issues.ref_closed_from=`<a href="%[3]s"> بسته شده این مسائله %[4]</a> <a id="%[1]s" href="#%[1]s">%[2]s</a>`
options/locale/locale_fa-IR.ini:issues.ref_reopened_from=`<a href="%[3]s"> بازگشایی این مسائله %[4]</a> <a id="%[1]s" href="#%[1]s">%[2]s</a>`

Also, in options/locale/locale_pt-BR.ini:

issues.due_date_remove=removeu a data limite %s %s

I do not know if this works as intended. I suppose it does, but other languages do it differently.

I still recommend that a proper QA for translation placeholders is implemented, especially checking that all placeholders are there. AFAIK, Weblate does this, it is Free Software. I have no experience with the proprietary Crowdin platform.

Also check out the corresponding @forgejo issue at https://codeberg.org/forgejo/forgejo/issues/863 - maybe there are some helpful discussions, too. I'll probably rather interact there.

@GiteaBot GiteaBot added the lgtm/need 2 This PR needs two approvals by maintainers to be considered for merging. label Jun 15, 2023
@lunny
Copy link
Member

lunny commented Jun 16, 2023

Thank you for your contribution, but we cannot merge this changes into translation files otherwise they may conflict with daily update from crowdin. But we can change them in crowdin follow your PR.

@lunny lunny closed this Jun 16, 2023
@wxiaoguang
Copy link
Contributor

wxiaoguang commented Jun 16, 2023

At the moment, the fixes could be done on Crowdin side.

After the INI package refactoring, I think there could be some tools to help to figure out/fix translation errors.


Let's keep it open until these translations get fixed.

@wxiaoguang wxiaoguang reopened this Jun 16, 2023
@wxiaoguang wxiaoguang mentioned this pull request Jul 3, 2023
@lunny
Copy link
Member

lunny commented Jul 3, 2023

Fixed in crowdin:

cs-CZ

de-DE

el-GR

fa-IR

is-IS

lv-LV

nl-NL

pl-PL

pt-BR

ru-RU

si-LK

sk-SK

tr-TR

uk-UA

And one key should be changed from all translation files.

  • dashboard.cron.cancelled

@wxiaoguang
Copy link
Contributor

@6543
Copy link
Member

6543 commented Jul 3, 2023

I'll merge main into this untill diff = 0 :)

silverwind pushed a commit that referenced this pull request Jul 3, 2023
partially fix #25291

---------

Co-authored-by: Lauris BH <lauris@nix.lv>
@6543 6543 reopened this Jul 3, 2023
@wxiaoguang
Copy link
Contributor

The crowdin fixes are in main now

6543 pushed a commit that referenced this pull request Jul 4, 2023
The backport needs manually checking because some 1.21 strings might not
be right for 1.20

This backport also includes most fixes from
#25291 (comment)
(thanks to lunny's manual fix on Crowdin side)

Close #25638
@pull-request-size pull-request-size bot added size/S and removed size/M labels Jul 4, 2023
@6543
Copy link
Member

6543 commented Jul 4, 2023

5 things are missing ...

@wxiaoguang
Copy link
Contributor

Only one is missing dashboard.task.unknown

Others are right (not wrong) on main branch.

@6543
Copy link
Member

6543 commented Jul 4, 2023

@6543 6543 closed this Jul 4, 2023
@wxiaoguang
Copy link
Contributor

I have made some changes:

@go-gitea go-gitea locked as resolved and limited conversation to collaborators Oct 2, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
lgtm/need 2 This PR needs two approvals by maintainers to be considered for merging.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants