Skip to content

script to rewrite yaml files using psych#22533

Merged
toy merged 3 commits into
release/17.3from
rewrite_crowdin_yml_files-script
Mar 31, 2026
Merged

script to rewrite yaml files using psych#22533
toy merged 3 commits into
release/17.3from
rewrite_crowdin_yml_files-script

Conversation

@toy
Copy link
Copy Markdown
Contributor

@toy toy commented Mar 26, 2026

Script to rewrite YAMLs downloaded using crowdin/github-action using ruby library, so that the auto merging script #22249 will not cause irrelevant style changes when auto resolving conflicts.

The script needs to first be present in dev and latest release branches to be able to use it from crowdin workflow changed in #22519.

@toy toy requested a review from Copilot March 26, 2026 17:41
@toy toy force-pushed the rewrite_crowdin_yml_files-script branch from b8dbdb6 to 2d72482 Compare March 26, 2026 17:42
@toy toy changed the base branch from dev to release/17.3 March 26, 2026 17:43
Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

Adds a Ruby script that rewrites Crowdin-downloaded locale YAML files using Psych so that subsequent auto-merges don’t introduce irrelevant YAML style diffs.

Changes:

  • Add script/i18n/rewrite_crowdin_yml_files to normalize YAML output via YAML.safe_load + YAML.dump
  • Preserve leading header comments from each YAML file before rewriting
  • Print a summary count of rewritten files

Comment thread script/i18n/rewrite_crowdin_yml_files
Comment thread script/i18n/rewrite_crowdin_yml_files
Comment thread script/i18n/rewrite_crowdin_yml_files Outdated
@toy toy requested a review from myabc March 26, 2026 17:44
@toy toy force-pushed the rewrite_crowdin_yml_files-script branch from 2d72482 to 4d4a71b Compare March 26, 2026 19:10
@toy toy mentioned this pull request Mar 26, 2026
Comment thread script/i18n/rewrite_crowdin_yml_files
Comment thread script/i18n/rewrite_crowdin_yml_files Outdated
Comment thread script/i18n/rewrite_crowdin_yml_files Outdated
toy and others added 3 commits March 30, 2026 19:23
Co-authored-by: Alexander Brandon Coles <a.coles@openproject.com>
Co-authored-by: Alexander Brandon Coles <a.coles@openproject.com>
@toy toy force-pushed the rewrite_crowdin_yml_files-script branch from 21652c9 to e45afcf Compare March 30, 2026 17:24
@myabc myabc self-requested a review March 31, 2026 07:54
Copy link
Copy Markdown
Contributor

@myabc myabc left a comment

Choose a reason for hiding this comment

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

Looks good! Thanks @toy!

@toy toy merged commit 52d5c95 into release/17.3 Mar 31, 2026
14 of 15 checks passed
@toy toy deleted the rewrite_crowdin_yml_files-script branch March 31, 2026 10:09
@github-actions github-actions Bot locked and limited conversation to collaborators Mar 31, 2026
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Development

Successfully merging this pull request may close these issues.

3 participants