Skip to content
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

fix issues in translation file #27699

Merged
merged 5 commits into from
Oct 22, 2023
Merged

fix issues in translation file #27699

merged 5 commits into from
Oct 22, 2023

Conversation

denyskon
Copy link
Member

@denyskon denyskon commented Oct 19, 2023

  • use correct comment sign for INI (;)
  • remove duplicated repo.branch.search key
  • remove duplicated spaces & similar

@GiteaBot GiteaBot added the lgtm/need 2 This PR needs two approvals by maintainers to be considered for merging. label Oct 19, 2023
@pull-request-size pull-request-size bot added the size/L Denotes a PR that changes 100-499 lines, ignoring generated files. label Oct 19, 2023
@denyskon denyskon added the skip-changelog This PR is irrelevant for the (next) changelog, for example bug fixes for unreleased features. label Oct 19, 2023
not_found = The target couldn't be found.
not_found = "The target couldn't be found."
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@wxiaoguang wasn't there something about quotes being bad for Crowdin?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

They're being used in many strings already.....

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The only problem is something like key = "the quoted string" is at the beginning

https://github.com/go-gitea/gitea/blob/main/modules/translation/i18n/i18n_test.go#L120C1-L120C93

@wxiaoguang
Copy link
Contributor

add quotes around translation where needed

I think most (or all) of them are not needed.

@silverwind
Copy link
Member

silverwind commented Oct 20, 2023

We need a better format than ini like yaml where such bikeshedding around quotes is automatically handled by a linter. Edit: Already planned as per #27700.

@6543
Copy link
Member

6543 commented Oct 20, 2023

best would be to write testcases to lint the locales file!!!!

could you write some tests for that?

@silverwind
Copy link
Member

I already checked and there are no usable linters for ini files around. We shouldn't invest too much energy in it, just move to a better format.

Copy link
Member

@delvh delvh left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM, hoping that it won't break anything

@GiteaBot GiteaBot added lgtm/need 1 This PR needs approval from one additional maintainer to be merged. and removed lgtm/need 2 This PR needs two approvals by maintainers to be considered for merging. labels Oct 21, 2023
@wxiaoguang
Copy link
Contributor

LGTM, hoping that it won't break anything

some changes like gpg_helper = "<strong>Need help?</strong> Have a look at GitHub's guide <a href="%s">about GPG</a>." doesn't seem right. The quote appears in other quotes

@denyskon
Copy link
Member Author

Seems like the consensus is that quotes rather introduce more problems, so I'll remove them again

@pull-request-size pull-request-size bot added size/M Denotes a PR that changes 30-99 lines, ignoring generated files. and removed size/L Denotes a PR that changes 100-499 lines, ignoring generated files. labels Oct 21, 2023
@pull-request-size pull-request-size bot added size/S Denotes a PR that changes 10-29 lines, ignoring generated files. and removed size/M Denotes a PR that changes 30-99 lines, ignoring generated files. labels Oct 21, 2023
@denyskon
Copy link
Member Author

I reverted the quote changes

@GiteaBot GiteaBot added lgtm/done This PR has enough approvals to get merged. There are no important open reservations anymore. and removed lgtm/need 1 This PR needs approval from one additional maintainer to be merged. labels Oct 22, 2023
@lunny lunny added the backport/v1.21 This PR should be backported to Gitea 1.21 label Oct 22, 2023
@lunny lunny enabled auto-merge (squash) October 22, 2023 11:35
@lunny lunny added the reviewed/wait-merge This pull request is part of the merge queue. It will be merged soon. label Oct 22, 2023
@lunny lunny merged commit 16cfa17 into go-gitea:main Oct 22, 2023
@GiteaBot GiteaBot added this to the 1.22.0 milestone Oct 22, 2023
@GiteaBot
Copy link
Collaborator

I was unable to create a backport for 1.21. @denyskon, please send one manually. 🍵

go run ./contrib/backport 27699
...  // fix git conflicts if any
go run ./contrib/backport --continue

@GiteaBot GiteaBot added backport/manual No power to the bots! Create your backport yourself! and removed reviewed/wait-merge This pull request is part of the merge queue. It will be merged soon. labels Oct 22, 2023
denyskon added a commit to denyskon/gitea that referenced this pull request Oct 22, 2023
- use correct comment sign for INI (`;`)
- remove duplicated `repo.branch.search` key
- remove duplicated spaces & similar
@denyskon denyskon added the backport/done All backports for this PR have been created label Oct 22, 2023
zjjhot added a commit to zjjhot/gitea that referenced this pull request Oct 23, 2023
* upstream/main:
  Fix incorrect ctx usage in defer function (go-gitea#27740)
  Enable followCursor for language stats bar (go-gitea#27713)
  teams: new View button (go-gitea#27685)
  fix issues in translation file (go-gitea#27699)
  Fix an indentation in the Chinese documentation of Act Runner (go-gitea#27730)
  [skip ci] Updated translations via Crowdin
  Fix org team endpoint (go-gitea#27721)
  Improve diff tree spacing (go-gitea#27714)
  refactor: make db iterate context aware (go-gitea#27710)
  [FIX] resolve confusing colors in languages stats by insert a gap (go-gitea#27704)
  Fix sticky diff header background (go-gitea#27697)
  Replace -1 with GhostUserID (go-gitea#27703)
  Clean some functions about project issue (go-gitea#27705)
lunny pushed a commit that referenced this pull request Oct 24, 2023
Backport #27699 

- use correct comment sign for INI (`;`)
- remove duplicated `repo.branch.search` key
- remove duplicated spaces & similar
@denyskon denyskon deleted the fix/translation branch November 19, 2023 13:50
fuxiaohei pushed a commit to fuxiaohei/gitea that referenced this pull request Jan 17, 2024
- use correct comment sign for INI (`;`)
- remove duplicated `repo.branch.search` key
- remove duplicated spaces & similar
@go-gitea go-gitea locked as resolved and limited conversation to collaborators Jan 20, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
backport/done All backports for this PR have been created backport/manual No power to the bots! Create your backport yourself! backport/v1.21 This PR should be backported to Gitea 1.21 lgtm/done This PR has enough approvals to get merged. There are no important open reservations anymore. modifies/translation size/S Denotes a PR that changes 10-29 lines, ignoring generated files. skip-changelog This PR is irrelevant for the (next) changelog, for example bug fixes for unreleased features.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

7 participants