You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Add MaterialCraft catalog migrated from its Rust translation table - #256
MaterialCraft still uses an Arabic Rust translation table. This PR migrates that snapshot to the shared catalogs as the prerequisite for a separate application runtime cutover.
Changes
Add locales/ar/materialcraft.tsv: 351 app rows, with 49 identical existing common rows reused. All 400 original Arabic translations resolve identically.
Add tools/export_materialcraft.py and migration instructions. Reuse the accepted Rust-table extraction/parity helpers through optional app and locale parameters; TextureCraft defaults remain unchanged.
Add five tests covering app isolation, differing shared overrides, read-only checks, changed/missing translations and real rustc extraction.
Record source, licensing, unchanged wording, tooling assistance and native-review status in ATTRIBUTION.md.
No common catalog, existing app catalog, application code or CI workflow is changed. English remains source text. The unmerged Hebrew catalog/font PRs storytold/materialcraft#197 and #198 are outside this snapshot; the runtime cutover must resync any locale work merged meanwhile.
Validation
On Windows with Python 3 and Rust 1.99.1:
MaterialCraft export --check: all 400 original rows resolve identically at the source SHA.
TextureCraft export --check: all 9,099 original translations remain identical with the parameterized helpers.
This PR does not close the MaterialCraft issue. After it is merged, the application PR will pin the actual accepted commit, integrate the runtime and run native, WebAssembly and visual checks. Hosted CI has not been run locally.
Summary by CodeRabbit
Documentation
Added guidance on the MaterialCraft Arabic catalog migration, including translation parity rules and steps required before a future runtime cutover.
Documented the upstream source, available locale, validation commands, and attribution details.
Chores
Added catalog migration and check support for MaterialCraft.
Shared translations are reused when identical, while differing MaterialCraft translations remain as app-specific overrides.
Added checks that detect missing or changed translations without modifying catalog files.
No actionable comments were generated in the recent review.
Walkthrough
The shared catalog exporter now accepts configurable languages, app names, and display names. A new CLI runs the exporter for MaterialCraft’s Arabic catalog. Tests cover overrides, check mode, and Rust extraction. New documentation and attribution record the migration source and validation details.
Changes: MaterialCraft catalog migration
Layer / File(s)
Summary
Configurable export and regression coverage tools/export_texturecraft.py, tools/test_export_materialcraft.py
The exporter accepts language mappings and app-specific catalog settings. Tests check shared-row omission, retained overrides, unchanged files in check mode, translation errors, and Arabic extraction.
MaterialCraft CLI and migration records tools/export_materialcraft.py, docs/materialcraft-migration.md, ATTRIBUTION.md
The CLI configures the exporter for MaterialCraft and Arabic. The documentation and attribution describe the source revision, catalog handling, and validation requirements.
storytold/craft-i18n#243: Adds the shared exporter functions that this change extends with language and app configuration.
Suggested reviewers:benandez, fredapps
Merge Risk: Minimal · up to ae1c9
This change adds an Arabic MaterialCraft catalog and migration tooling without changing application code or existing catalogs. No actionable merge-blocking risk was found.
Pre-merge checks: 4
Check name
Status
Explanation
Description Check
Check skipped - CodeRabbit’s high-level summary is enabled.
Title check
The title "Add MaterialCraft catalog migrated from its Rust translation table" matches the main change. The PR adds an Arabic MaterialCraft catalog (locales/ar/materialcraft.tsv, excluded from the sum…
Linked Issues check
Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check
Check skipped because no linked issues were found for this pull request.
Full details: Title check
Explanation
The title "Add MaterialCraft catalog migrated from its Rust translation table" matches the main change. The PR adds an Arabic MaterialCraft catalog (locales/ar/materialcraft.tsv, excluded from the summary but described in the objectives) migrated from the Rust translation table, along with the export tooling, documentation, tests, and attribution. The title is specific and concise, and it names the primary change. It does not mention the shared-helper parameter changes, but those are supporting work.
Finishing Touches
Generate unit tests (beta)
Create a new PR
Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.
Reviewing files that changed from the base of the PR and between 74e7770 and ae1c994.
Files ignored due to path filters: 1
locales/ar/materialcraft.tsv is excluded by !**/*.tsv
Files selected for processing: 5
ATTRIBUTION.md
docs/materialcraft-migration.md
tools/export_materialcraft.py
tools/export_texturecraft.py
tools/test_export_materialcraft.py
Included review availability: This review used your included allowance. Your plan provides up to 1 included review per hour; 0 remain after this review.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Part of storytold/materialcraft#210.
MaterialCraft still uses an Arabic Rust translation table. This PR migrates that snapshot to the shared catalogs as the prerequisite for a separate application runtime cutover.
Changes
locales/ar/materialcraft.tsv: 351 app rows, with 49 identical existing common rows reused. All 400 original Arabic translations resolve identically.tools/export_materialcraft.pyand migration instructions. Reuse the accepted Rust-table extraction/parity helpers through optional app and locale parameters; TextureCraft defaults remain unchanged.ATTRIBUTION.md.Source snapshot: storytold/materialcraft@b73facdc7b8b5ce102cd9e14d964058a15182dc0, MIT OR Apache-2.0.
No common catalog, existing app catalog, application code or CI workflow is changed. English remains source text. The unmerged Hebrew catalog/font PRs storytold/materialcraft#197 and #198 are outside this snapshot; the runtime cutover must resync any locale work merged meanwhile.
Validation
On Windows with Python 3 and Rust 1.99.1:
--check: all 400 original rows resolve identically at the source SHA.--check: all 9,099 original translations remain identical with the parameterized helpers.python -m unittest discover -s tools: 46 passed.cargo test --workspace: 49 passed, no failures.cargo fmt --all --check: passed.cargo clippy --workspace --all-targets --all-features -- -D warnings: passed.This PR does not close the MaterialCraft issue. After it is merged, the application PR will pin the actual accepted commit, integrate the runtime and run native, WebAssembly and visual checks. Hosted CI has not been run locally.
Summary by CodeRabbit
Documentation
Chores