Skip to content

Omarchy in 50 languages - #15326

Merged
dhh merged 48 commits into
quattrofrom
fifty-languages
Oct 14, 2026
Merged

dhh merged 48 commits into
quattrofrom
fifty-languages

Conversation

@dhh

@dhh dhh commented Oct 13, 2026 •

Copy link
Copy Markdown
Contributor

What this does

Omarchy now speaks the same 50 languages as omarchy.org (the fifty-languages roster: 56 site editions collapse to 50 languages because the regional English editions share English text). English remains the default and the per-string fallback.

Pick a language under Setup > Language — native names, English first, searchable by English name, checkmark on the current one — or run omarchy language <code>. The menu, the Quickshell desktop, and Omarchy's own notifications switch immediately (the shell watches the language file, no restart), and the system locale is set to match so third-party apps follow on the next login.

How it works

  • default/i18n/locales.json — the 50-language registry (native/English names, format locale, glibc locale, direction), mirrored from omarchy-site.
  • default/i18n/<code>/{menu,shell,cli}.json — string catalogs; English in en/ is the source of truth and every language mirrors its keys and placeholders exactly (397 menu ids, 166 shell keys, 111 CLI keys).
  • manual/<code>/ — the full manual, all 51 chapters per language (2,499 files), same structure, links, and code blocks as English.
  • bin/omarchy-language — show/set/list; persists ~/.config/omarchy/language, generates the glibc locale when needed, and writes LANG in /etc/locale.conf (leaving LC_* alone, same convention as install/config/locale.sh). Launched from the menu without a terminal, it continues in a floating terminal for the sudo step, like omarchy-default-browser --install.
  • bin/omarchy-i18n — prints a cli.json string in the current language; 49 commands' notifications now route through it.
  • shell/Commons/I18n.qml — shell singleton layering the current shell.json over English; 151 QML call sites plus the audio/monitor/clipboard JS models (via an optional tr argument, so Node tests still assert English).
  • Menu: MenuModel.applyTranslations retitles shipped rows before the user extension merges (user retitles win; English labels stay searchable via search-only terms, never routable aliases), plus a languages provider for the picker.
  • Stock noto-fonts + noto-fonts-cjk already cover every script in the roster, so no font installs are needed.

docs/i18n.md documents the architecture, how to add strings, and the translator brief. Danish was the pilot, verified live in the running shell; the remaining 48 catalog sets and all manuals were translated with one agent per language and validated for key/placeholder parity, heading/URL/code-fence parity, and completeness.

Deliberately not translated (yet)

  • Terminal/usage/diagnostic CLI output, the developer gallery, and plugin manifest names/descriptions.
  • RTL languages (ar, ur, fa, he) render text correctly via Qt bidi, but shell layout is not mirrored.
  • Plural-sensitive strings use a single form.
  • The website keeps its manual in English (manual: false there); these translations are ahead of it and can be picked up later.

Keeping translations in sync

Individual PRs only add the English side. The i18n-check workflow validates structure on PRs (English freshness, placeholders, no English literals embedded directly in code) without requiring translations. The Sync translations workflow — modeled on omarchy-site's — then converges the rest: a credential-less runner extracts any embedded English into a patch that a separate trusted job path-checks, validates, and publishes; one credential-less Muse runner per language translates whatever default/i18n/translation-manifest.json (per-unit English source hashes) marks pending; and everything lands as an auto-merging PR gated on i18n-check. The exception is an extraction that changed executable code under bin/ or shell/ — that PR deliberately waits for human review instead of auto-merging. Tooling: scripts/i18n-sync.py (also runnable locally). Needs the MUSE_API_KEY secret, an I18N_SYNC_TOKEN secret (fine-grained PAT with contents + pull-requests write, so the bot PR actually triggers checks — GITHUB_TOKEN PRs do not), "Allow auto-merge" enabled, and i18n-check as a required check on quattro. i18n-check runs on every PR and passes trivially when nothing i18n-relevant changed, so requiring it cannot block unrelated PRs.

Tests

New test/shell.d/i18n-test.sh: registry shape, English menu catalog freshness against omarchy-menu.jsonc, exact key/placeholder parity for all 49 languages, referenced-key checks both ways, complete manuals, and omarchy-language/omarchy-i18n behavior against stubbed locale files.

dhh and others added 6 commits October 13, 2026 15:09
Registry, English source catalogs, and runtime translation for the menu,
Quickshell desktop, and CLI notifications, with English as the default
and per-string fallback. omarchy-language also sets the system locale.
Danish ships as the first complete translation.

Co-Authored-By: Muse <[email protected]>
Menu, shell, and CLI catalogs for every language in the registry,
mirroring the English keys and placeholders.

Co-Authored-By: Muse <[email protected]>
Every chapter under manual/<code>/, mirroring the English structure,
links, and code blocks.

Co-Authored-By: Muse <[email protected]>
Declare textFormat on newly dynamic Text bindings, translate the
ConfirmDialog Delete/Uninstall buttons, and point source-level test
assertions and the yt-dlp fixture at the catalog mechanism.

Co-Authored-By: Muse <[email protected]>
English labels move to search-only terms so routing is identical in
every language; omarchy-language only hands off to a terminal when
privileged locale work remains and persists after applying; CLI
catalogs switch to %1 tokens so translations can reorder arguments;
catalog rebuilds skip the guard batch; leftover prompts and tooltips
join the catalogs.

Co-Authored-By: Muse <[email protected]>
@greptile-apps

greptile-apps Bot commented Oct 13, 2026 •

Copy link
Copy Markdown
Contributor

RetriggerConfidence Score: 4/5

[Medium impact] Adds internationalization framework across all shell scripts.

The PR appears safe to merge, with non-blocking fixes for notification text, custom menu headings, and manual tests.

Findings

  1. P2 Ampersands corrupt notification text ▶
  2. P2 Custom menu headings disappear ▶
  3. P2 Broken manual commands pass tests ▶

Summary

Adds 50-language support for the menu, desktop shell, and Omarchy notifications, plus translated manuals.

  • People can choose an Omarchy language and set the matching system locale.
  • The Omarchy menu and desktop switch to the selected language without a restart.
  • Selected Omarchy command messages appear in the chosen language.
  • Omarchy's full manual is available in 49 additional languages.

Diagram

%%{init: {'theme': 'neutral'}}%%
flowchart TD
  Picker["Setup > Language"] --> Command["omarchy-language"]
  CLI["omarchy language code"] --> Command
  Command --> Locale["Generate locale and write LANG"]
  Locale --> Choice["Save user language"]
  Choice --> Watchers["Shell file watchers"]
  Watchers --> Menu["Translate shipped menu rows"]
  Menu --> User["Merge user menu rows"]
  Watchers --> Shell["Layer shell catalog over English"]
  Choice --> Notifications["omarchy-i18n reads CLI catalog"]
  Locale --> Login["Other apps use locale on next login"]
Loading

Reviews (1) · Last reviewed commit: "Address review: routable aliases, termin..." · Reviewed by Greptile

Comment thread bin/omarchy-i18n Resolved
Comment thread shell/plugins/menu/Menu.qml Resolved
Comment thread test/shell.d/i18n-test.sh Resolved
dhh and others added 2 commits October 14, 2026 01:55
Individual PRs only add the English side; a scheduled workflow
extracts embedded English, translates whatever the source-hash
manifest marks pending (one Muse runner per language), and lands
it as an auto-merging PR gated on the structural i18n check.

Co-Authored-By: Muse <[email protected]>
@dhh

dhh commented Oct 14, 2026

Copy link
Copy Markdown
Contributor Author

Codex review of the sync automation

Codex reviewed b8826eb7e (Add translation sync automation) read-only and found eight actionable issues. Commit 1330685d5 addresses all eight:

  1. Extraction ran with write credentials. Extraction now runs credential-less (contents: read, persist-credentials: false) and only produces a patch. A separate trusted publish-extract job path-checks and validates the patch before pushing it, and a sync run whose extraction touched executable code under bin/ or shell/ no longer enables auto-merge — it waits for human review.
  2. English deletions or placeholder edits could wedge their own repair. The structural gate is now staleness-aware via the manifest hashes: stale translations, orphaned keys, and prune-pending manual chapters no longer fail the PR gate, so an English-only edit can land and be converged by the sync workflow (which prunes deterministically).
  3. Bot PRs made with GITHUB_TOKEN never trigger checks. Publishing and PR creation now use an I18N_SYNC_TOKEN secret (fine-grained PAT: contents + pull-requests write) when present, falling back to GITHUB_TOKEN with a documented human-nudge caveat.
  4. A path-filtered required check would block unrelated PRs. i18n-check now runs on every PR and passes trivially when nothing i18n-relevant changed.
  5. Empty-patch translations never advanced the manifest. collect now reads completion sidecars independently of patch size, so an English edit that legitimately needs no change in a language still advances its hash.
  6. Manual validation accepted changed commands and broken links. Validation now compares fenced code-block contents, relative link/image destinations, and machine-significant inline code (paths, variables, omarchy commands).
  7. Catalog membership exempted embedded literals. The literal in en_values exemption is removed — matching a catalog value now suggests a reusable key instead of hiding the literal. This surfaced untranslated hero/status strings in the Agents, Bluetooth, and Dropbox panels, which are now catalog keys (33 new shell keys, translated into all 49 languages).
  8. Completion sidecars could forge other locales. A sidecar must now contain exactly its own locale, and manifest rejects any recorded unit whose translation is not actually in the tree. The i18n test covers all three sidecar cases.

Verification on 1330685d5: full test/shell.d/i18n-test.sh exit 0, structural mode exit 0, extract-scan --check clean, pending empty, ./test/cli exit 0, and the agents/bluetooth/dropbox panel tests pass. test/shell.d/menu-guards-test.sh fails on omarchy-dock guard readers, but that failure reproduces identically on the base commit a268c1983, so it is pre-existing and unrelated.

One heads-up: quattro has moved since this branch was cut, and GitHub now reports the PR as conflicting. The only real conflict is bin/omarchy-agent-account-use, where upstream switched the notification headline from $active to $label on the same line this PR routes through omarchy-i18n — the resolution is to keep both. The tray, clipboard, and image-picker overlaps auto-merge cleanly and add no new English literals.

@dhh

dhh commented Oct 14, 2026

Copy link
Copy Markdown
Contributor Author

Merged quattro, performance verified

quattro (ecf0eb362) is merged into this branch. The single conflict in bin/omarchy-agent-account-use kept both changes: upstream's shorter $label headline, routed through omarchy-i18n. Upstream's new tray-drawer paragraph in the top-bar chapter is translated into all 49 languages (the new code line inserted verbatim, since fence bodies are verbatim), the manifest is regenerated, pending is empty again, and all 2,499 translated chapters pass the strengthened manual validator. That sweep also caught six older chapters where a synopsis placeholder had been localized ([ficheiro...] and friends); the validator now erases [...] placeholders the way it already erased <...>, and still catches changed commands, broken relative links, and altered code blocks. One Polish link was also put back in angle brackets so its parenthesized URL parses everywhere. And i18n-check now passes on this PR on GitHub (29s).

Performance, measured on this machine against plain quattro:

Surface Cost
omarchy-i18n lookup 2.5 ms median per call (n=30); only on notification paths
Menu parse (396 items) 0.396 ms vs 0.401 ms pre-i18n — unchanged
MenuModel.applyTranslations (Danish) 0.067 ms for all 396 items
Catalog JSON parse (shell + menu) ~0.1 ms
CLI benchmark indistinguishable from quattro (omarchy 5.2 vs 5.5 ms, omarchy commands 202 vs 206 ms, omarchy screenshot --help 193 vs 192 ms)
Menu guard budget 67 ms batch (budget 200 ms), slowest guard 38 ms
Theme switch budget 66 ms (budget 500 ms)
Idle shell no processes spawned over 30 s — the language layer is FileView watches (inotify), no timers, no polling

Full and structural test/shell.d/i18n-test.sh, ./test/cli, extract-scan --check, and the Agents, tray, clipboard, bar, battery, channel, and image-picker tests all pass on the merged branch. test/shell.d/menu-guards-test.sh still fails on uncovered omarchy-dock guard readers, but it fails identically on quattro itself, so it predates this PR.

Still needs repository settings after merge: MUSE_API_KEY and I18N_SYNC_TOKEN secrets, "Allow auto-merge" enabled, and i18n-check required on quattro. The sync workflow itself cannot run until it lands on quattro, so its first live run should be watched.

dhh and others added 15 commits October 14, 2026 03:49
Qt.formatDate and a bare Qt.locale() follow the system LANG, which only
catches up at the next login. The bar clock, the calendar heading, and the
week start now use the language's formatLocale; the month title takes the
standalone month name, and the date patterns that vary by language live in
the catalog. The remaining clock labels go through I18n.t().

Co-Authored-By: Claude Opus 5.5 <[email protected]>
Picked from the menu there is no terminal for sudo, so the switch used to
open a floating terminal just to ask for a password. Generating the locale
and setting LANG now run as one elevated script: pkexec without a terminal,
sudo with one, so there is a single prompt either way. A cancelled prompt
still leaves the language unchanged.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
The status notification and the power panel's time left were assembled in
English. The line, its durations, and the holding/charging phrases now come
from the catalog, and the power reading is joined with no-break spaces so a
longer language wraps between the parts instead of inside "13.1W / 53Wh".

Tests now pin the language to English, so a machine set to another language
does not fail assertions on English output.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
Every panel, bar widget, indicator, dialog, and menu string the earlier pass
missed now goes through I18n.t(), and the notifications, menu prompts, and
confirmations the commands show go through omarchy-i18n: hero phrases,
tooltips, statuses, section headers, empty states, the polkit and lock
prompts, gum's Yes/No buttons, and the agents panel's sign-in help.

Values that are stored, compared, or answered over IPC stay English and are
translated only where they are displayed. Sentences are whole keys with
placeholders, with a separate key for exactly one where English pluralizes,
and dates use the language's formatLocale rather than the system locale.
Terminal output, usage text, and diagnostics stay English.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
A translated label can be much longer than the English it replaced, and a
button laid out at a fixed width (the DNS provider pills) let it spill over
its border. The label now spends half its padding first, then shrinks to
fit, and elides only when even the smallest size does not.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
The catalogs loaded asynchronously, so bindings evaluated at startup got
the raw key back, briefly showing it and logging QString::arg warnings for
keys with placeholders. They are small local files, now read synchronously.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
Third-party shell plugins can ship their own catalogs as i18n/<code>.json
and read them through Commons.Translations, which follows the language live
and falls back from pt-BR to pt to English per string. The omarchy skill's
plugin guide shows how, and the omarchy-app skill gives apps a small
JSON-backed QTranslator so they keep plain qsTr() and switch with the
desktop, with templates that build and test as written.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
The extractor only knew a few exact property names, so tooltipText,
activeTooltipText, leftLabel, and hero phrase lists slipped past it. It
now flags any display-text property, every literal on such a line, and
bare string-list items, skips identifiers, and honors an "i18n: ignore"
line marker for values that must stay English.

Muse now gets reference translations from the same areas and guidance for
playful phrases, Qt date patterns, short units, and plural pairs, so new
strings match the terms each language already uses. The key-reference
check also skips __pycache__, which tests can leave in bin/.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
Fills the shell strings in all 49 languages and the command strings in
the 30 that ran after they landed, recorded in the translation manifest.
The rest are pending for the next sync.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
Nothing in Omarchy escapes a percent sign, and Turkish writes it before the
number, so "%%2" is a correct translation of "%2%". The test now counts
placeholders the way the sync script's validator does.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
A misplaced brace nested the Uninstall row inside the Keep in Dock row,
so it drew over it instead of below, and vanished with it when there was
no dock to keep apps in.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
A catalog value can now be an object of CLDR plural categories, and each
translation supplies exactly the forms its language's counts reach: one
and other in English, one/few/many in Russian, six in Arabic, one in
Japanese. The rules live in Plural.js for the shell and plural.jq for
omarchy-i18n, checked against each other in every language; the sync
script asks plural.jq which forms Muse must return. I18n.tn() and
omarchy-i18n --count pick the form.

Numbers follow the language through the registry's decimal separator and
digits, taken from Qt: I18n.formatNumber() in the shell, and omarchy-i18n
localizes plain-number arguments (or --number for one value). I18n also
exposes rightToLeft from the registry, Util.readingKey() maps Left and
Right along the reading direction, and OMARCHY_LANGUAGE_FILE pins the
shell's language the way it already pinned omarchy-i18n's, so tests no
longer follow the machine's language.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
Every string that counts something is now a plural entry, read with
I18n.tn() or omarchy-i18n --count, replacing the separate "…One" keys and
the English-only count == 1 branches. Every displayed number goes through
I18n.formatNumber() or a plain-number argument to omarchy-i18n, so Danish
reads "13,1 W" and Persian its own digits.

Arabic, Hebrew, Persian, and Urdu mirror the panels, menus, notifications,
and dialogs with LayoutMirroring. Things placed by explicit x arithmetic
(slider knobs, ticks, the day-length strip, toggle knobs) follow the
mirroring, back and forward glyphs swap, and Left/Right keys move along
the reading direction. The bar keeps the user's arrangement, the dock
strip keeps its slot order, and the Wi-Fi QR code and transport controls
are never mirrored.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
The plugin guide covers plural entries through Commons.Translations.tn(),
numbers through I18n.formatNumber(), and what mirroring does and doesn't
flip. The app template's Translator now picks plural forms for
qsTr("%n clips", "", n), loads English plural forms from en.json, takes
the locale from Omarchy's registry so numbers match the desktop, and sets
the layout direction for a mirrored root; it builds and tests as written.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
@emirb emirb added this to the 4.5 milestone Oct 17, 2026
scottjones added a commit to omacom/omarchy-mac-pkgs that referenced this pull request Oct 19, 2026
#14675, the runtime's fingerprint-readers detector, merged into quattro
as 81fd2d23ca6e. The pin moves from its head to that merge commit, and
both Touch ID integration tests run against it.

That runtime also has omacom/omarchy#15326, so the reset prints its
prompts through omarchy-i18n. The factory-reset test sources the reset's
functions with only its stubs and the system PATH, so every prompt
failed with "command not found"; it now links the runtime's omarchy-i18n
and its catalogs into the fixture.

Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]>
namespaceMarcello added a commit to namespaceMarcello/omarchy that referenced this pull request Oct 19, 2026
Since this branch was cut, omacom#15326 moved the Taildrop arrival notice's text
to omarchy-i18n and omacom#13353 gave every file the glyph instead of an image
preview; the click still opens the file with xdg-open, a .desktop included.
The guard merges cleanly onto the new notice. omacom#13353's test reads the busctl
call the notice makes, so the two .desktop cases are redone in that form:
assert_notification takes --no-open and checks that the toast carries no
omarchy-exec-argv hint and no copy of the path.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
omarchybot added a commit to iskakaushik/omarchy that referenced this pull request Oct 22, 2026
Since this branch was cut, quattro builds panel content on first open (omacom#15044), routes every string through I18n with catalogs (omacom#15326), restyled the copy menu for right-to-left layouts, and qualifies palette references for Qt 6.12. The branch's intent is ported onto that structure rather than the old one restored.

The machine list, its search field and the shared copy menu now live inside the lazily built content, so root-level code reaches them through `panel.loadedContent` like the panel's other items, and every root caller tolerates them being null before the first open. The account-switch reset still records the last account seen while the panel has never opened, so the first open after a switch is not mistaken for one. The shared copy menu takes quattro's right-to-left placement, opening from whichever end the row's copy button sits at, and `Commons.Color`. The machine count, search placeholder, loading and no-match texts get English catalog entries, with the counts formatted for the language.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
@Afsharimahdi

Copy link
Copy Markdown

WWAN / Mobile Broadband Support Request

Hardware: HP laptop with built-in HP lt4120 Snapdragon X5 LTE modem (03f0:9d1d).
Status: Modem is recognized by mmcli after manually applying the FCC unlock UDEV rule. NetworkManager successfully connects via nmcli using a GSM profile (cdc-wdm0 shows connected).
Issue: The Omarchy network panel (Quickshell) does not display the mobile broadband connection or a cellular signal icon in the top bar. The current network model only supports Wi-Fi and Ethernet.

Request:
Please consider merging this PR to add the "Mobile Broadband" row to the network panel and display the cellular signal icon when a WWAN modem is connected. This feature is crucial for users relying on LTE-enabled laptops.

Environment:

  • ModemManager version: 1.24.2
  • NetworkManager: Active GSM connection via nmcli
  • Omarchy version: [Insert your version here, e.g., 4.0.4]

nekomario28 added a commit to nekomario28/omarchy that referenced this pull request Oct 23, 2026
The commands under test call each other: omarchy-battery-status runs
omarchy-i18n, and omarchy-i18n reads OMARCHY_PATH. A test run from a checkout
had neither on hand, so any test whose command reaches another one failed with
`omarchy-i18n: command not found` or `OMARCHY_PATH: unbound variable`.
test/shell.d/i18n-test.sh already exports both for itself; base-test.sh, which
the rest source, did not.

bash test/shell on quattro: 32 of 419 files fail. With these two lines: 17 of
419, and every one of the 17 also fails before this change, so nothing new
fails. Four of the fifteen are a regression from the language work (omacom#15326):
battery-status, crash-capture, hyprland-workspace-layout and keybindings-menu
pass at 84cfb93^ and fail at 84cfb93.
Elshayib added a commit to Elshayib/omarchy that referenced this pull request Oct 25, 2026
The regression assertion matched the bare word, so the i18n comment upstream added in omacom#15326 ("Profile names are powerprofilesctl ids") tripped it and the test failed on current quattro even though the provider routes through the wrapper. Match an invocation with a subcommand instead, which is what the guard is meant to catch.
shawnduggan added a commit to shawnduggan/omarchy that referenced this pull request Oct 29, 2026
Resolve conflicts with the virtualized machine list (omacom#7623) and the panel
translations (omacom#15326): publishPeers now writes the cached _peers that the
visible peers list derives from, the offline switch sits beside the counted
MACHINES header, and the new switch, empty-state and Offline strings are
English catalog entries. The runtime fixture builds the lazily created panel
content (omacom#15044), feeds statuses as full peer fetches, and qualifies its
palette references (omacom#14553).

Co-Authored-By: Claude Opus 5.5 <[email protected]>
Claude-Session: https://claude.ai/code/session_01CFeF4GVPAdJb4fXF29e79S
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants