Repository navigation
T-1238 Cry Bot 界面语言只留中文和英文,去掉其余 14 种 - #66
Merged
Merged
Conversation
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
# Conflicts: # src/lib/i18n.test.ts # src/locales/pt-br.json # src/locales/zh.json
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Contributor
Author
|
操作者通过 --allow-credential-hit 放行以下凭据扫描命中(仅列位置):
|
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
crysound-it
marked this pull request as ready for review
November 15, 2026 10:47
# Conflicts: # server/routes/config-instabox.test.ts # src/locales/pt-br.json
Contributor
Author
|
操作者通过 --allow-credential-hit 放行以下凭据扫描命中(仅列位置):
|
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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
台账任务
台账任务:T-1238
改了什么
T-1238:界面语言只保留简体中文和英文
盘点
src/locales/en.json、src/locales/zh.jsonsrc/locales/source-hashes.jsonzh条目;en是源目录src/locales/*-words.test.ts、server-lines.test.ts、i18n 与语言偏好测试localeChoices检查,覆盖 en/zh 与旧值回退shared/languages.tsSUPPORTED_LANGUAGE_CODES、localePacks、supportedLanguage();旧码仅保留在兼容识别表src/locales/index.ts、src/lib/i18n.ts、src/lib/language-preference.tsserver/language.ts、server/server-lines.ts、server/server-line-packs.ts、server/initial-greeting.ts、server/routine-cron-text.ts、server/workspace.ts、server/host/{brief-words,first-hour-words}.ts、server/saved-steps/screen-words.tselectron/native-text.cjs、electron/lending-words.mjs、菜单、桌面偏好和相关测试mobile/ios/scripts/gen-strings.mjs、mobile/ios/CryBot/Strings/ServerText.xcstrings、mobile/ios/project.ymlen、zh-Hansmobile/android/app/src/main/res/values*、mobile/ios/CryBotWatch/{en,zh-Hans}.lprojshared/announcements.ts、announcements/announcements.schema.json、公告 fixturescripts/generate-locale.mjs及测试删除的资源为
de、es、fr、hi、it、ja、ko、pl、pt-br、ru、tr、uk、vi、zh-tw,以及它们对应的src/locales目录资源和生成内容。兼容规则
zh、zh-*、包括zh-TW、zh-Hant-TW,统一使用简体中文包zh。de-DE、pt-BR)统一回退英文en。验证
依赖准备:已在 worktree 根目录运行 依赖准备脚本。
通过的类型和静态检查:
pnpm exec tsc -b --pretty falsepnpm exec tsc -p tsconfig.server.json --pretty falsepnpm exec oxlint --deny-warnings ...git diff --checknode scripts/generate-locale.mjs --check:locale catalogs valid (2 languages, 10608 English strings),zh 为8014/10608。node scripts/check-announcements.mjs:announcements: valid。通过的语言相关 Vitest 文件:
shared/languages.test.ts:2 testssrc/lib/i18n.test.ts:39 testssrc/lib/language-preference.test.ts:13 testssrc/lib/cloud-send.test.ts:20 testssrc/lib/server-error.test.ts:6 testsserver/language.test.ts:3 testsserver/server-lines.test.ts:3 testsserver/host/brief-words.test.ts:12 testsserver/host/first-hour-words.test.ts:5 testssrc/locales/server-lines.test.ts:8 testsserver/skill-switch.test.ts:9 testsshared/announcements.test.ts:21 testssrc/lib/announcements.test.ts:18 testssrc/testing/preview-locale.test.ts:3 testssrc/locales/trial-days.test.ts:3 testssrc/locales/vocabulary.test.ts:6 testssrc/locales/credential-store-words.test.ts:1 testsrc/locales/native-keys.test.ts:3 testsdata-keys(1)、departments(2)、everyday-words(3,另 3 todo)、mcp-sign-in-path(1)、screen-words(1)、sent-keys(2)、settings-words(2)、vm-confirm(1)、welcome-words(2)、words(3)。electron/menu.test.mjs:21 tests通过的 Node 测试:
node --test electron/native-text.node-test.mjsnode --test electron/native-language.node-test.mjsnode --test electron/lend-automatically.node-test.mjsnode --test electron/lending-dialogs.node-test.mjsnode --test electron/desktop-prefs.node-test.mjsnode --test electron/environments.node-test.mjsnode --test electron/error-pages.node-test.mjsnode --test electron/move-gaps.node-test.mjsnode --test electron/team-move-bring.node-test.mjsnode --test electron/startup-tray.node-test.mjsnode --test electron/screen-status.node-test.mjsnode --test electron/talk-panel.node-test.mjsnode --test electron/credential-patch.node-test.mjsnode --test electron/cloud-first-open.node-test.mjs验收证据
审核、安全审查和测试结论见本 PR 检查状态及评论。
风险与回退
待补充风险;合并后可通过 revert 压缩提交回退。
🤖 Generated with Claude Code