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
Rework project README with new centered header, logo, badges, Quick Start, package/format tables, and clearer AI workflow docs. Update CLI examples (output path, models to gpt-5.4) and add use_tolgee=true in example config. Add docs/langcodec-icon.svg asset. Bump langcodec crate version in langcodec/README.md to 0.10.0 and tidy up links to CLI and library guides.
Most localization workflows are a pile of one-off scripts, format-specific tools, spreadsheet exports, and CI glue. `langcodec` gives you one Rust-native toolkit for the loop teams actually run:
39
+
40
+
- move between Apple, Android, and tabular formats without losing structure
41
+
- inspect stale, missing, or incomplete strings before they ship
42
+
- normalize files so diffs stay readable in review and CI
43
+
- draft translations with AI-backed providers
44
+
- generate better translator comments from real source usage
45
+
- sync `.xcstrings` catalogs with Tolgee without custom release scripts
2
46
3
-
`langcodec` is a Rust toolkit for working with localization files across Apple, Android, and spreadsheet-style workflows.
4
-
5
-
It gives you one consistent model for parsing, converting, inspecting, editing, merging, normalizing, and translating files like:
6
-
7
-
- Apple `.strings`
8
-
- Apple `.xcstrings`
9
-
- Android `strings.xml`
10
-
- CSV
11
-
- TSV
47
+
## Highlights
12
48
13
-
This workspace includes:
49
+
- Unified data model for singular and plural translations
50
+
- Read and write support for Apple `.strings`, Apple `.xcstrings`, Android `strings.xml`, CSV, and TSV
51
+
- CLI commands for convert, diff, merge, sync, edit, normalize, view, stats, debug, translate, annotate, and Tolgee sync
52
+
- Config-driven AI workflows with `langcodec.toml`
53
+
- Rust library API for teams building custom localization pipelines
14
54
15
-
-`langcodec`: the Rust library crate
16
-
-`langcodec-cli`: the `langcodec` command-line tool
55
+
## Quick Start
17
56
18
-
## Why People Use It
57
+
Install the CLI:
19
58
20
-
Localization pipelines usually get messy when teams have to move between iOS, Android, translators, spreadsheets, and CI scripts. `langcodec` is built to reduce that friction.
59
+
```sh
60
+
cargo install langcodec-cli
61
+
```
21
62
22
-
With one toolchain, you can:
63
+
Use the library:
23
64
24
-
- convert catalogs between Apple, Android, CSV, and TSV
25
-
- inspect missing or stale entries
26
-
- merge and sync translations safely
27
-
- edit files in place across formats
28
-
- normalize files to reduce noisy diffs
29
-
- generate draft translations with AI-backed providers
30
-
- generate translator-facing xcstrings comments from source usage
langcodec edit set -i en.strings -k welcome_title -v "Welcome"
115
-
langcodec normalize -i values/strings.xml
116
-
```
117
-
118
-
### Merge and sync
119
-
120
-
```sh
121
-
langcodec merge -i a.xcstrings -i b.xcstrings -o merged.xcstrings --strategy last
122
-
langcodec sync --source source.xcstrings --target target.xcstrings --match-lang en
123
-
```
124
-
125
-
### AI workflows with config
126
-
127
-
Create a `langcodec.toml` in your project:
118
+
`langcodec` is built for app localization workflows, not just isolated text snippets. `translate` and `annotate` can be driven from a shared `langcodec.toml`, use supported providers such as OpenAI, Anthropic, and Gemini, and scale from a single catalog to config-driven runs across larger repos.
128
119
129
120
```toml
130
121
[openai]
131
122
model = "gpt-5.4"
132
123
133
124
[translate]
134
125
concurrency = 4
126
+
use_tolgee = true
135
127
136
128
[translate.input]
137
129
source = "locales/Localizable.xcstrings"
@@ -153,15 +145,12 @@ Then run:
153
145
```sh
154
146
langcodec translate
155
147
langcodec annotate
148
+
langcodec tolgee pull
156
149
```
157
150
158
-
When exactly one provider section is configured, `translate` and `annotate` use it automatically. If you configure multiple providers, choose one with `--provider` or `translate.provider`. For larger projects, `translate.input.sources = [...]` can fan out parallel runs from config.
151
+
For deeper CLI examples, head to [langcodec-cli/README.md](./langcodec-cli/README.md).
159
152
160
-
`annotate` also supports `annotate.inputs = [...]` for config-driven in-place runs across multiple xcstrings files.
161
-
162
-
More CLI details live in [langcodec-cli/README.md](langcodec-cli/README.md).
-[tests](tests): shared test data and integration coverage
197
-
198
-
## Current Status
199
-
200
-
The current release is `0.10.0` on [crates.io](https://crates.io/crates/langcodec). It is already useful in real workflows, but it is still a `0.x` project, so APIs and behavior may continue to evolve.
201
-
202
-
## Contributing
172
+
The library is a good fit if you want to build custom pipelines, validate assets in CI, or work with a consistent representation instead of format-specific parsers.
0 commit comments