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

Extract messages #20022

Merged
merged 6 commits into from
Oct 21, 2023
Merged

Extract messages #20022

merged 6 commits into from
Oct 21, 2023

Conversation

rob006
Copy link
Contributor

@rob006 rob006 commented Oct 20, 2023

Alternative for #19996.

In addition to #19996:

  1. I tried to fix some translations that has changed placeholder name (see this diff).
  2. Forced order - this PR is hard to review mostly because phrases changed their position. On long run it would be easier to review any change here if all messages will be ordered. Untranslated messages can be easily found by searching for => ''.

{attribute} must be greater than or equal to "{compareValueOrAttribute}".
{attribute} must be less than "{compareValueOrAttribute}".
{attribute} must be less than or equal to "{compareValueOrAttribute}".
{nFormatted} GB
{nFormatted} kB
{nFormatted} MB
{nFormatted} PB
{nFormatted} TB
{nFormatted} {n, plural, =1{gigabyte} other{gigabytes}}
{nFormatted} {n, plural, =1{kilobyte} other{kilobytes}}
{nFormatted} {n, plural, =1{megabyte} other{megabytes}}
{nFormatted} {n, plural, =1{petabyte} other{petabytes}}
{nFormatted} {n, plural, =1{terabyte} other{terabytes}}
@codecov
Copy link

codecov bot commented Oct 20, 2023

Codecov Report

Attention: 2038 lines in your changes are missing coverage. Please review.

Comparison is base (5eeb12f) 49.02% compared to head (871bc4a) 47.87%.

Additional details and impacted files
@@            Coverage Diff             @@
##           master   #20022      +/-   ##
==========================================
- Coverage   49.02%   47.87%   -1.16%     
==========================================
  Files         445      445              
  Lines       42849    43879    +1030     
==========================================
  Hits        21005    21005              
- Misses      21844    22874    +1030     
Files Coverage Δ
framework/messages/el/yii.php 0.00% <0.00%> (ø)
framework/messages/config.php 0.00% <0.00%> (ø)
framework/messages/sk/yii.php 0.00% <0.00%> (ø)
framework/messages/af/yii.php 0.00% <0.00%> (ø)
framework/messages/be/yii.php 0.00% <0.00%> (ø)
framework/messages/bg/yii.php 0.00% <0.00%> (ø)
framework/messages/ja/yii.php 0.00% <0.00%> (ø)
framework/messages/zh/yii.php 0.00% <0.00%> (ø)
framework/messages/fr/yii.php 0.00% <0.00%> (ø)
framework/messages/ru/yii.php 0.81% <0.00%> (-0.02%) ⬇️
... and 43 more

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@rob006
Copy link
Contributor Author

rob006 commented Oct 21, 2023

BTW: please use "squash and merge" while merging this PR, I used really bad commit messages...

@bizley bizley merged commit 5f3d36e into yiisoft:master Oct 21, 2023
47 of 49 checks passed
@bizley bizley added this to the 2.0.50 milestone Oct 21, 2023
@NabiKAZ
Copy link
Contributor

NabiKAZ commented Oct 21, 2023

It seems to be merged but I just wanted to clarify.
Two default parameters in config.php have been changed, while it was applied with command line parameters and only for this order.

  • The sort of untranslated items is not very interesting and if they are at the same end, they will be seen much better instead of searching through all the files.
  • Deleting @@ items is also good, but not as a default, and if they exist by default, and if the user wishes, he can delete them with the relevant parameter.
    Anyway, this was my personal opinion.

image

@rob006 rob006 deleted the messages branch October 21, 2023 16:34
@rob006
Copy link
Contributor Author

rob006 commented Oct 21, 2023

@NabiKAZ With fixed order it is much easier to review diff, since it is clear which messages were added, changed or removed. It is not so clear if you start moving messages across the file.

@bizley
Copy link
Member

bizley commented Oct 22, 2023

I agree with @rob006 - sorted is better

@NabiKAZ
Copy link
Contributor

NabiKAZ commented Oct 22, 2023

@bizley
They will sort!
The subject of sort is the untranslated items that used to appear at the end of all translations and were separated so that they were easily visible to the translator.
But now they are mixed with all other translated and untranslated expressions, which makes it difficult to find untranslated items.

@bizley
Copy link
Member

bizley commented Oct 23, 2023

I don't think this is a big problem. Easy to find with quick search.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants