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
[Feature Request] Add i18n support / Chinese localization #1219
Is your feature request related to a problem? Please describe.
CodeBurn is a great local tool for tracking AI coding token usage, but the UI (CLI output and the local dashboard) is hardcoded in English only. It is quite popular among Chinese developers, and a localized version would make it much more accessible to them.
Describe the solution you would like
Add internationalization support:
Extract user-facing strings from src/ and dash/src/ into resource files
Support a --lang / config option (e.g. LANG env or codeburn config set lang zh-CN)
Ship at least en and zh-CN (Simplified Chinese) locales
Apply to both the CLI/Ink UI and the web dashboard
Describe alternatives you have considered
A third-party translation patch fork (fragile, hard to maintain)
Keeping it English-only (fine, but limits adoption)
Additional context
The codebase currently has no i18n library (no i18next / react-i18next in dependencies)
Happy to help with implementation / PR review if the maintainers are open to it
I am happy to submit a PR if the direction is agreed. Thanks for the great tool!
Hi — I've been running a Simplified Chinese build of the macOS menubar app for a while and would like to contribute it, if the approach fits.
What it looks like on the Swift side (no third-party library):
Localizable.strings in en.lproj / zh-Hans.lproj shipped in the main bundle, so every SwiftUI literal (Text("…"), Button("…"), .help("…") …) resolves on its own.
Two tiny helpers for the rest: L("…") (String(localized:), keeps interpolation as %@/%lld) for plain-String UI text, and LR(x) for labels that arrive at runtime from the CLI payload (activity names, period labels), which look themselves up and fall back to the English text.
A Settings › General › Language picker (System / English / 简体中文) that writes the per-app AppleLanguages default, plus two small scripts (extract_keys.py / merge_strings.py) so another language is just another .lproj.
~720 strings translated; English remains the development language, so nothing changes for existing users.
This is only the menubar app — the CLI/Ink output and the web dashboard from the original request are a separate job (different stack), and I'd keep them out of this PR.
I have the branch ready and can open the PR right away if you're open to it. Happy to adjust the mechanism (e.g. String Catalogs) if you'd prefer a different shape.
The macOS menubar half is up as #1289: Localizable.strings for en and zh-Hans shipped as SwiftPM target resources, no third-party library, language chosen by the system, which matches the approach @TheCrazyAnt described above. @TheCrazyAnt, you have been running a zh-Hans build for a while, so your review of the translation would be worth more than anything else on that PR; corrections welcome as suggestions or as a follow-up commit. The CLI and web dashboard are a different stack and stay out of scope for now; I will write up the policy for those here separately.
Activity
TheCrazyAnt commentedon Sep 3, 2026
Hi — I've been running a Simplified Chinese build of the macOS menubar app for a while and would like to contribute it, if the approach fits.
What it looks like on the Swift side (no third-party library):
Localizable.stringsinen.lproj/zh-Hans.lprojshipped in the main bundle, so every SwiftUI literal (Text("…"),Button("…"),.help("…")…) resolves on its own.L("…")(String(localized:), keeps interpolation as%@/%lld) for plain-String UI text, andLR(x)for labels that arrive at runtime from the CLI payload (activity names, period labels), which look themselves up and fall back to the English text.AppleLanguagesdefault, plus two small scripts (extract_keys.py/merge_strings.py) so another language is just another.lproj.This is only the menubar app — the CLI/Ink output and the web dashboard from the original request are a separate job (different stack), and I'd keep them out of this PR.
I have the branch ready and can open the PR right away if you're open to it. Happy to adjust the mechanism (e.g. String Catalogs) if you'd prefer a different shape.
mac: Simplified Chinese localization, language picker, Capacity Dock …
mac: Simplified Chinese localization, language picker, Capacity Dock …
ozymandiashh commentedon Sep 11, 2026
The macOS menubar half is up as #1289:
Localizable.stringsforenandzh-Hansshipped as SwiftPM target resources, no third-party library, language chosen by the system, which matches the approach @TheCrazyAnt described above. @TheCrazyAnt, you have been running a zh-Hans build for a while, so your review of the translation would be worth more than anything else on that PR; corrections welcome as suggestions or as a follow-up commit. The CLI and web dashboard are a different stack and stay out of scope for now; I will write up the policy for those here separately.feat(menubar): route every user-facing string through a strings catalog
test(menubar): assert the en and zh-Hans catalogs cannot drift apart