localship 0.1.0 → 0.3.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +54 -44
- package/dist/{chunk-OWT47JBL.js → chunk-GNL5EFNP.js} +1017 -517
- package/dist/cli.js +72 -41
- package/dist/{server-GZNS57EQ.js → server-5AITZXZV.js} +30 -18
- package/package.json +2 -1
- package/skills/localship/SKILL.md +66 -43
- package/skills/localship-extract/SKILL.md +123 -39
- package/skills/localship-extract/references/platform-localization.md +65 -0
- package/skills/localship-review/SKILL.md +11 -2
- package/skills/localship-setup/SKILL.md +50 -36
- package/skills/localship-translate/SKILL.md +32 -19
package/README.md
CHANGED
|
@@ -6,6 +6,7 @@
|
|
|
6
6
|
|
|
7
7
|
Free and open source · No account, no server · Any AI model · Every translation checked
|
|
8
8
|
|
|
9
|
+
[](https://www.npmjs.com/package/localship)
|
|
9
10
|
[](https://github.com/jigarfumakiya/localship/actions/workflows/ci.yml)
|
|
10
11
|
[](LICENSE)
|
|
11
12
|
[](https://modelcontextprotocol.io)
|
|
@@ -31,39 +32,41 @@ no server, no monthly bill.
|
|
|
31
32
|
|
|
32
33
|
- 🆓 **Free and open source.** MIT-licensed. You pay only for your own AI usage, or nothing with a
|
|
33
34
|
local model.
|
|
34
|
-
- 🤖 **
|
|
35
|
-
|
|
36
|
-
- 🛡️ **Catches broken translations.** Placeholders, plural forms,
|
|
37
|
-
|
|
35
|
+
- 🤖 **Your AI, your model.** Your coding agent's own model, or Claude, GPT, Gemini, OpenRouter
|
|
36
|
+
or Ollama.
|
|
37
|
+
- 🛡️ **Catches broken translations.** Placeholders, plural forms, escaping and markup are checked
|
|
38
|
+
in code before anything is written. Failures go back to the AI with the reason.
|
|
38
39
|
- 🧠 **More context for the AI.** Each string comes with the code that uses it, its comment, your
|
|
39
40
|
glossary and voice notes, and earlier translations of the same text.
|
|
40
|
-
- 🔒 **
|
|
41
|
-
|
|
41
|
+
- 🔒 **Your files, your workflow.** No Localship server or account. Translation files stay in your
|
|
42
|
+
repo, formatted the way your tools write them. You choose the AI that receives their content.
|
|
43
|
+
- ✅ **Check before release.** Require current, approved translations in CI with
|
|
44
|
+
`localship validate --require-approved`. No model call or API key needed for the check.
|
|
42
45
|
- 💻 **Runs anywhere.** Claude Code, Cursor, VS Code, Codex, Gemini CLI, Claude Desktop or the
|
|
43
46
|
terminal, on macOS, Linux and Windows.
|
|
44
47
|
|
|
45
48
|
### 🤔 Why use Localship?
|
|
46
49
|
|
|
47
|
-
Your AI can already translate a strings file if you ask. Here's what changes with Localship:
|
|
48
|
-
|
|
49
50
|
| | ❌ Asking an AI directly | ✅ With Localship |
|
|
50
51
|
|---|---|---|
|
|
51
|
-
|
|
|
52
|
-
|
|
|
53
|
-
|
|
|
54
|
-
|
|
|
55
|
-
|
|
|
56
|
-
|
|
|
52
|
+
| Context | One string at a time | Code, comments, brief and glossary |
|
|
53
|
+
| Placeholders | Sometimes dropped | Checked before writing |
|
|
54
|
+
| Plural forms | Often incomplete | Every form each language needs |
|
|
55
|
+
| Escaping and markup | Can break the build | Checked and escaped |
|
|
56
|
+
| Terms and tone | Drift across strings | Same glossary and voice everywhere |
|
|
57
|
+
| Changed copy | Everything redone | Only what changed |
|
|
58
|
+
| Your edits | Overwritten | Kept |
|
|
59
|
+
|
|
60
|
+
For a comparison with Lingo.dev, Crowdin, Lokalise and i18n Ally, see the
|
|
61
|
+
[plugin review](docs/plugin-review.md).
|
|
57
62
|
|
|
58
63
|
## 🎬 See it in action
|
|
59
64
|
|
|
60
65
|
```
|
|
61
66
|
You: Translate this app into Hindi and Arabic.
|
|
62
|
-
Agent:
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
You: Start translating.
|
|
66
|
-
Agent: 36 translations written as drafts, 0 errors. Arabic has all six plural forms.
|
|
67
|
+
Agent: Translating 18 strings into Hindi and Arabic…
|
|
68
|
+
36 translations written as drafts, 0 errors. Arabic has all six plural forms.
|
|
69
|
+
Hindi addresses the user as आप, and "Jotter Pro" is kept as written.
|
|
67
70
|
|
|
68
71
|
You: Review the Arabic, then approve them.
|
|
69
72
|
Agent: Two small fixes made. All approved.
|
|
@@ -127,47 +130,52 @@ Wherever your app is today, one sentence gets it started.
|
|
|
127
130
|
Android string arrays and plurals, String Catalog plural variations, and gettext plural forms are
|
|
128
131
|
all supported.
|
|
129
132
|
|
|
130
|
-
|
|
131
|
-
|
|
132
|
-
|
|
133
|
+
Apple device/nested variations and substitutions, and Android strings in configuration-specific
|
|
134
|
+
folders such as `values-ar-night`, are preserved but not translated or validated. Localship reports
|
|
135
|
+
these coverage gaps; `validate --strict` and `--require-approved` fail rather than claim completeness.
|
|
136
|
+
See [platform verification](skills/localship-extract/references/platform-localization.md) for native
|
|
137
|
+
build, language setup and device checks.
|
|
133
138
|
|
|
134
|
-
|
|
139
|
+
## 🚀 Install
|
|
135
140
|
|
|
136
|
-
**Claude Code
|
|
141
|
+
**Claude Code plugin**
|
|
137
142
|
|
|
138
143
|
```
|
|
139
144
|
/plugin marketplace add jigarfumakiya/localship
|
|
140
145
|
/plugin install localship@localship
|
|
141
146
|
```
|
|
142
147
|
|
|
143
|
-
**
|
|
144
|
-
step-by-step playbooks your agent follows. The first time, it offers to install the Localship
|
|
145
|
-
command line it uses.
|
|
148
|
+
**Claude Code, Codex, Gemini CLI and other CLIs:** add the server, then the skills.
|
|
146
149
|
|
|
147
150
|
```sh
|
|
148
|
-
|
|
151
|
+
claude mcp add localship -- npx -y localship mcp # Claude Code
|
|
152
|
+
codex mcp add localship -- npx -y localship mcp # Codex
|
|
153
|
+
gemini mcp add localship npx -y localship mcp # Gemini CLI
|
|
154
|
+
npx skills add jigarfumakiya/localship # the skills, for any agent
|
|
149
155
|
```
|
|
150
156
|
|
|
151
|
-
|
|
157
|
+
**Cursor and VS Code**
|
|
158
|
+
|
|
159
|
+
[](https://cursor.com/en/install-mcp?name=localship&config=eyJjb21tYW5kIjoibnB4IiwiYXJncyI6WyIteSIsImxvY2Fsc2hpcCIsIm1jcCJdfQ%3D%3D)
|
|
160
|
+
[](https://insiders.vscode.dev/redirect?url=vscode%3Amcp%2Finstall%3F%257B%2522name%2522%253A%2522localship%2522%252C%2522command%2522%253A%2522npx%2522%252C%2522args%2522%253A%255B%2522-y%2522%252C%2522localship%2522%252C%2522mcp%2522%255D%257D)
|
|
161
|
+
|
|
162
|
+
Add the skills too: `npx skills add jigarfumakiya/localship`.
|
|
163
|
+
|
|
164
|
+
Now ask your agent: *"Translate this app into Hindi and Arabic."* Needs Node.js 22 or newer.
|
|
152
165
|
|
|
153
166
|
### 🔌 Other tools
|
|
154
167
|
|
|
155
|
-
Add
|
|
168
|
+
Add this MCP server to your tool's config:
|
|
156
169
|
|
|
157
170
|
```json
|
|
158
171
|
{ "mcpServers": { "localship": { "command": "npx", "args": ["-y", "localship", "mcp"] } } }
|
|
159
172
|
```
|
|
160
173
|
|
|
161
|
-
| Tool |
|
|
174
|
+
| Tool | Config file |
|
|
162
175
|
|---|---|
|
|
163
|
-
|
|
|
164
|
-
|
|
|
165
|
-
|
|
|
166
|
-
| Gemini CLI | `.gemini/settings.json` |
|
|
167
|
-
| Codex | `~/.codex/config.toml`: `[mcp_servers.localship]` with `command = "npx"` and `args = ["-y", "localship", "mcp"]` |
|
|
168
|
-
| Claude Desktop | `claude_desktop_config.json`, with `"-C", "/path/to/your/app"` added before `"mcp"` |
|
|
169
|
-
|
|
170
|
-
The first start takes a minute while it installs.
|
|
176
|
+
| Cursor | `.cursor/mcp.json` |
|
|
177
|
+
| VS Code | `.vscode/mcp.json` (use `"servers"`) |
|
|
178
|
+
| Claude Desktop | `claude_desktop_config.json` (add `"-C", "/path/to/app"` before `"mcp"`) |
|
|
171
179
|
|
|
172
180
|
<details>
|
|
173
181
|
<summary><b>MCP tools</b></summary>
|
|
@@ -176,8 +184,8 @@ Your agent picks these itself; you just ask. 👀 marks tools that only read and
|
|
|
176
184
|
|
|
177
185
|
| Tool | What it does |
|
|
178
186
|
|---|---|
|
|
179
|
-
| `localship_plan` 👀 | Looks at
|
|
180
|
-
| `localship_start` |
|
|
187
|
+
| `localship_plan` 👀 | Looks at what a request involves: files, strings to translate, anything in the way |
|
|
188
|
+
| `localship_start` | Writes the config for the languages, or adds them to it |
|
|
181
189
|
| `localship_status` 👀 | Progress per language: missing, changed, drafts, approved |
|
|
182
190
|
| `localship_validate` 👀 | Checks placeholders, plural forms, escaping, markup and the glossary |
|
|
183
191
|
| `localship_detect` 👀 | Finds translation files in the repo |
|
|
@@ -198,9 +206,10 @@ Your agent picks these itself; you just ask. 👀 marks tools that only read and
|
|
|
198
206
|
|
|
199
207
|
- **Stays in your project.** Localship reads and writes only your translation files and the
|
|
200
208
|
`.localship/` folder. Changes to your code are made by your agent, where you can see them.
|
|
201
|
-
- **No Localship server.** No account, no telemetry.
|
|
202
|
-
|
|
203
|
-
|
|
209
|
+
- **No Localship server.** No account, no telemetry. Localship's model calls go to the provider
|
|
210
|
+
you configure. When you use a cloud coding agent, that agent may send strings and context to
|
|
211
|
+
its model provider. Validation runs locally without model calls; translation can also stay
|
|
212
|
+
local when you use a locally hosted model.
|
|
204
213
|
- **Nothing is final until you say so.** Translations are written as drafts, and hand edits and
|
|
205
214
|
approved translations are never replaced unless you ask.
|
|
206
215
|
|
|
@@ -216,6 +225,7 @@ localship start hi,ar --model anthropic:claude-sonnet-5-5 # set up and transla
|
|
|
216
225
|
localship status # progress per language
|
|
217
226
|
localship validate # exits 1 on errors
|
|
218
227
|
localship approve --locale hi # after review
|
|
228
|
+
localship validate --require-approved # release / CI check
|
|
219
229
|
```
|
|
220
230
|
|
|
221
231
|
Every command, option and config key is in the [reference](docs/reference.md).
|