@prettifystudio/lyngo-cli
v0.2.6
Published
Localization for Laravel applications, from the terminal: Lyngo wraps user-facing text with your framework's i18n call, reuses your project's keys, translates and verifies the catalogs. Blade, Livewire, PHP, and Inertia with React, Vue or Svelte.
Maintainers
Readme
lyngo
Manual: https://docs.lyngo.app (every page also as Markdown; https://docs.lyngo.app/llms-full.txt for agents).
Localization for Laravel applications, from your terminal: Blade, Livewire, PHP, and Inertia with React, Vue or Svelte. Your agent builds the product; Lyngo keeps it localized.
When you or your agent add text a person reads, lyngo localize wraps it with
your project's i18n calls, reuses the keys you already have, and translates the
catalogs with your glossary, translation memory and plural rules, before you
commit. The files come back to your working tree as one patch. A model never
holds them.
Install
You need a Lyngo account (lyngo.app) and Node 20 or newer.
npm i -g @prettifystudio/lyngo-cli
lyngo login # opens the browser once; the token goes to ~/.config/lyngo/token
cd your-repository
lyngo init # project, i18n setup, languages, agent hooklyngo init does this, in order:
- Shows the workspace it uses.
--workspace <name>picks another one. - Finds the Lyngo project for the repository's
originremote, or creates it when you own the workspace. When the Lyngo GitHub App cannot read the repository yet, it prints the GitHub link where you add it; in a terminal it waits until you have, in an agent or a script it stops, and the next run continues (--waitmakes it wait anyway). - Detects the framework and the i18n library.
- Sets the languages:
--languages fr,de, or it asks. - Applies the i18n setup as a patch to your working tree. It edits
package.jsonbut never runsnpm install; it prints the command. - When Claude Code is installed: registers the Lyngo MCP server for this
repository in Claude Code's local scope (stored in your home folder, never in
the repository), and adds one Stop hook to
.claude/settings.local.jsonthat runslyngo localize --hookwhen your agent finishes a task.
Run it again at any time: it prints the state and changes nothing that is already set up.
Daily use
- With an agent: build as usual. The hook runs
lyngo localize --hookat the end of every task. You see one line (what was localized and translated); the agent gets the full report and tells you what changed. It stays silent when nothing changed, and sends a file again only after it is edited. - Without an agent: run
lyngo localizebefore you commit. - A repository that was never localized:
lyngo localize --allonce. It walks every source file a scan would read, in batches, and leaves the result in your working tree to review and commit. No pull request. - Anything pushed without it still gets a pull request from the Lyngo GitHub App.
Commands
| Command | What it does |
|---|---|
| lyngo login | Signs in through the browser and saves the token (mode 600) |
| lyngo logout | Revokes the token and deletes it from this machine |
| lyngo whoami | The account, the token prefix and your workspaces |
| lyngo init | Connects the repository (see above). Flags: --languages, --workspace, --yes, --github |
| lyngo localize | Localizes and translates what changed in the working tree. Flags: --all (the whole repository, in batches of 30), --languages, --no-translate, --dry, --hook (the Claude Code Stop hook) |
| lyngo check <file> | The user-facing strings of one file |
| lyngo status | The project as Lyngo knows it |
Configuration: LYNGO_HOST (default https://lyngo.app), LYNGO_TOKEN
(otherwise ~/.config/lyngo/token). Revoke tokens in Lyngo under Settings, CLI.
The Claude Code plugin (optional)
This repository is also a Claude Code plugin. It adds the commands
/lyngo:init, /lyngo:localize, /lyngo:status and /lyngo:login, and the
lyngo-i18n skill, which makes the agent check existing keys before it writes
new text. It needs the lyngo command from npm; lyngo init prints these two
lines when the plugin is not installed yet.
claude plugin marketplace add prettifystudio/lyngo-claude-plugin
claude plugin install lyngo@lyngoOther MCP clients
Server https://lyngo.app/mcp, headers Authorization: Bearer <token> and
X-Lyngo-Remote: <the repository's git remote URL>. Tools: status, lookup,
check.
