fix: retire rules/zh from the always-loaded default rules install#2170
fix: retire rules/zh from the always-loaded default rules install#2170konstapukarifastnetfi wants to merge 1 commit into
Conversation
rules/zh shipped ~17KB of Chinese rule text into the auto-loaded rules tree of every default install (rules-core installs the bare 'rules' path with defaultInstall: true), with no paths: frontmatter gating. The content had also drifted behind both rules/common and the maintained translations in docs/zh-CN/rules/common (e.g. zh/coding-style.md 48 lines vs the 52-line docs/zh-CN copy), and 'zh' was already dropped from the installer's language help in favor of the gated docs-zh-cn locale module (--locale zh-CN). - move rules/zh/code-review.md to docs/zh-CN/rules/common/code-review.md: the only file with no counterpart in the maintained locale tree (fills a zh-CN parity gap with rules/common/code-review.md) - delete the remaining 10 rules/zh files, all older duplicates of docs/zh-CN/rules/common content - update trae-install test to assert the rules tree via rules/web instead Not addressed here: rules/README.md (~5.5KB of installer docs) still ships into the auto-loaded tree via the bare 'rules' module path; filtering README files from rule-tree expansion is a separate decision
|
PR changed again? Review this PR in Change Stack to compare snapshots and stay oriented. No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: defaults Review profile: CHILL Plan: Pro Run ID: 📒 Files selected for processing (13)
💤 Files with no reviewable changes (11)
📝 WalkthroughWalkthroughThis pull request removes all Chinese localized documentation from ChangesChinese Documentation Cleanup
Estimated code review effort🎯 2 (Simple) | ⏱️ ~8 minutes Poem
🚥 Pre-merge checks | ✅ 4 | ❌ 1❌ Failed checks (1 warning)
✅ Passed checks (4 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. ✨ Finishing Touches🧪 Generate unit tests (beta)
Warning There were issues while running some tools. Please review the errors and either fix the tool's configuration or disable the tool if it's a critical failure. 🔧 ESLint
ESLint install failed. For unrecoverable errors, disable the tool in CodeRabbit configuration. 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. Comment |
What Changed
rules/zh/tree (~17 KB of drifted Chinese rule translations) plusrules/zh/README.mdinstaller docs from the default rule treerules/zh/code-review.md) to its correct gated home:docs/zh-CN/rules/common/code-review.mdtests/scripts/trae-install.test.js: replaced the now-broken positive manifest assertion with a valid substitute (rules/web/performance.md)tests/lib/install-targets.test.js: removed the negative Cursor-plan assertion that referenced the deletedrules/zh/README.md(it passed vacuously after the deletion); the adjacentrules/README.mdassertion still covers the behaviorWhy This Change
rules-coreinstalls the wholerules/directory, so every default install auto-loads the drifted zh translations and installer READMEs into session context. Thedocs-zh-cnlocale module (--locale zh-CN) is the gated home for Chinese content; the remaining 10 deleted files were already covered by maintained copies underdocs/zh-CN/rules/common/.Testing Done
docs/zh-CNcounterpart (or was moved there)node tests/run-all.js) - full suite 2619/2619 in a clean Linux container (node:22-bookworm, freshnpm ci)rules/README.mdnegative assertionType of Change
fix:Bug fixSecurity & Quality Checklist
Documentation
Summary by cubic
Retired
rules/zhfrom the defaultrules/install to stop auto-loading outdated Chinese translations; moved the only unique file to the gateddocs/zh-CNlocale. This keeps zh content behind--locale zh-CNand reduces noise in session context.rules/zh/and its README from the always-installed rule tree (~11 files, ~17 KB).rules/zh/code-review.mdtodocs/zh-CN/rules/common/code-review.mdto preserve zh parity.rules/web/performance.mdintests/scripts/trae-install.test.js; removed the obsolete negative assertion referencingrules/zh/README.mdintests/lib/install-targets.test.js.Written for commit 4a07369. Summary will update on new commits.
Summary by CodeRabbit
Documentation
Tests