lingo.dev 0.121.1 → 0.122.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/build/cli.cjs +32 -32
- package/build/cli.cjs.map +1 -1
- package/build/cli.mjs +31 -31
- package/build/cli.mjs.map +1 -1
- package/package.json +11 -11
package/build/cli.mjs
CHANGED
|
@@ -86,7 +86,7 @@ function _loadDefaults() {
|
|
|
86
86
|
};
|
|
87
87
|
}
|
|
88
88
|
function _loadEnv() {
|
|
89
|
-
return Z.
|
|
89
|
+
return Z.looseObject({
|
|
90
90
|
LINGODOTDEV_API_KEY: Z.string().optional(),
|
|
91
91
|
LINGODOTDEV_API_URL: Z.string().optional(),
|
|
92
92
|
LINGODOTDEV_WEB_URL: Z.string().optional(),
|
|
@@ -97,14 +97,14 @@ function _loadEnv() {
|
|
|
97
97
|
GOOGLE_API_KEY: Z.string().optional(),
|
|
98
98
|
OPENROUTER_API_KEY: Z.string().optional(),
|
|
99
99
|
MISTRAL_API_KEY: Z.string().optional()
|
|
100
|
-
}).
|
|
100
|
+
}).parse(process.env);
|
|
101
101
|
}
|
|
102
102
|
function _loadSystemFile() {
|
|
103
103
|
const settingsFilePath = _getSettingsFilePath();
|
|
104
104
|
const content = fs.existsSync(settingsFilePath) ? fs.readFileSync(settingsFilePath, "utf-8") : "";
|
|
105
105
|
const data = Ini.parse(content);
|
|
106
|
-
return Z.
|
|
107
|
-
auth: Z.
|
|
106
|
+
return Z.looseObject({
|
|
107
|
+
auth: Z.looseObject({
|
|
108
108
|
apiKey: Z.string().optional(),
|
|
109
109
|
apiUrl: Z.string().optional(),
|
|
110
110
|
webUrl: Z.string().optional(),
|
|
@@ -112,7 +112,7 @@ function _loadSystemFile() {
|
|
|
112
112
|
apiKey: Z.string().optional()
|
|
113
113
|
}).optional()
|
|
114
114
|
}).optional(),
|
|
115
|
-
llm: Z.
|
|
115
|
+
llm: Z.looseObject({
|
|
116
116
|
openaiApiKey: Z.string().optional(),
|
|
117
117
|
anthropicApiKey: Z.string().optional(),
|
|
118
118
|
groqApiKey: Z.string().optional(),
|
|
@@ -120,7 +120,7 @@ function _loadSystemFile() {
|
|
|
120
120
|
openrouterApiKey: Z.string().optional(),
|
|
121
121
|
mistralApiKey: Z.string().optional()
|
|
122
122
|
}).optional()
|
|
123
|
-
}).
|
|
123
|
+
}).parse(data);
|
|
124
124
|
}
|
|
125
125
|
function _saveSystemFile(settings) {
|
|
126
126
|
const settingsFilePath = _getSettingsFilePath();
|
|
@@ -10870,7 +10870,7 @@ import { createAnthropic } from "@ai-sdk/anthropic";
|
|
|
10870
10870
|
import { createGoogleGenerativeAI } from "@ai-sdk/google";
|
|
10871
10871
|
import { createOpenRouter } from "@openrouter/ai-sdk-provider";
|
|
10872
10872
|
import { createMistral } from "@ai-sdk/mistral";
|
|
10873
|
-
import { createOllama } from "ollama-ai-provider";
|
|
10873
|
+
import { createOllama } from "ollama-ai-provider-v2";
|
|
10874
10874
|
function createProcessor(provider, params) {
|
|
10875
10875
|
if (!provider) {
|
|
10876
10876
|
const result = createLingoLocalizer(params);
|
|
@@ -11198,7 +11198,7 @@ function checkIfFileExists(filePath) {
|
|
|
11198
11198
|
import * as path16 from "path";
|
|
11199
11199
|
import YAML5 from "yaml";
|
|
11200
11200
|
var LockSchema = z.object({
|
|
11201
|
-
version: z.literal(1).
|
|
11201
|
+
version: z.literal(1).prefault(1),
|
|
11202
11202
|
checksums: z.record(
|
|
11203
11203
|
z.string(),
|
|
11204
11204
|
// localizable files' keys
|
|
@@ -11208,8 +11208,8 @@ var LockSchema = z.object({
|
|
|
11208
11208
|
z.string(),
|
|
11209
11209
|
// checksum of the key's value in the source locale
|
|
11210
11210
|
z.string()
|
|
11211
|
-
).
|
|
11212
|
-
).
|
|
11211
|
+
).prefault({})
|
|
11212
|
+
).prefault({})
|
|
11213
11213
|
});
|
|
11214
11214
|
function createDeltaProcessor(fileKey) {
|
|
11215
11215
|
const lockfilePath = path16.join(process.cwd(), "i18n.lock");
|
|
@@ -11797,8 +11797,8 @@ function parseFlags(options) {
|
|
|
11797
11797
|
strict: Z3.boolean().optional(),
|
|
11798
11798
|
key: Z3.string().optional(),
|
|
11799
11799
|
file: Z3.array(Z3.string()).optional(),
|
|
11800
|
-
interactive: Z3.boolean().
|
|
11801
|
-
debug: Z3.boolean().
|
|
11800
|
+
interactive: Z3.boolean().prefault(false),
|
|
11801
|
+
debug: Z3.boolean().prefault(false)
|
|
11802
11802
|
}).parse(options);
|
|
11803
11803
|
}
|
|
11804
11804
|
async function validateAuth(settings) {
|
|
@@ -12032,7 +12032,7 @@ function createLockfileHelper() {
|
|
|
12032
12032
|
}
|
|
12033
12033
|
}
|
|
12034
12034
|
var LockfileSchema = Z4.object({
|
|
12035
|
-
version: Z4.literal(1).
|
|
12035
|
+
version: Z4.literal(1).prefault(1),
|
|
12036
12036
|
checksums: Z4.record(
|
|
12037
12037
|
Z4.string(),
|
|
12038
12038
|
// localizable files' keys
|
|
@@ -12042,8 +12042,8 @@ var LockfileSchema = Z4.object({
|
|
|
12042
12042
|
// key
|
|
12043
12043
|
Z4.string()
|
|
12044
12044
|
// checksum of the key's value in the source locale
|
|
12045
|
-
).
|
|
12046
|
-
).
|
|
12045
|
+
).prefault({})
|
|
12046
|
+
).prefault({})
|
|
12047
12047
|
});
|
|
12048
12048
|
|
|
12049
12049
|
// src/cli/cmd/lockfile.ts
|
|
@@ -12093,7 +12093,7 @@ var lockfile_default = new Command15().command("lockfile").description(
|
|
|
12093
12093
|
}
|
|
12094
12094
|
});
|
|
12095
12095
|
var flagsSchema = Z5.object({
|
|
12096
|
-
force: Z5.boolean().
|
|
12096
|
+
force: Z5.boolean().prefault(false)
|
|
12097
12097
|
});
|
|
12098
12098
|
|
|
12099
12099
|
// src/cli/cmd/cleanup.ts
|
|
@@ -12579,7 +12579,7 @@ import chalk10 from "chalk";
|
|
|
12579
12579
|
import dedent7 from "dedent";
|
|
12580
12580
|
import { generateText as generateText2 } from "ai";
|
|
12581
12581
|
import { jsonrepair as jsonrepair3 } from "jsonrepair";
|
|
12582
|
-
import { createOllama as createOllama2 } from "ollama-ai-provider";
|
|
12582
|
+
import { createOllama as createOllama2 } from "ollama-ai-provider-v2";
|
|
12583
12583
|
function createExplicitLocalizer(provider) {
|
|
12584
12584
|
const settings = provider.settings || {};
|
|
12585
12585
|
switch (provider.id) {
|
|
@@ -13551,13 +13551,13 @@ var flagsSchema2 = z2.object({
|
|
|
13551
13551
|
frozen: z2.boolean().optional(),
|
|
13552
13552
|
verbose: z2.boolean().optional(),
|
|
13553
13553
|
strict: z2.boolean().optional(),
|
|
13554
|
-
interactive: z2.boolean().
|
|
13555
|
-
concurrency: z2.number().positive().
|
|
13556
|
-
debug: z2.boolean().
|
|
13554
|
+
interactive: z2.boolean().prefault(false),
|
|
13555
|
+
concurrency: z2.number().positive().prefault(10),
|
|
13556
|
+
debug: z2.boolean().prefault(false),
|
|
13557
13557
|
sourceLocale: z2.string().optional(),
|
|
13558
13558
|
targetLocale: z2.array(z2.string()).optional(),
|
|
13559
|
-
watch: z2.boolean().
|
|
13560
|
-
debounce: z2.number().positive().
|
|
13559
|
+
watch: z2.boolean().prefault(false),
|
|
13560
|
+
debounce: z2.number().positive().prefault(5e3),
|
|
13561
13561
|
// 5 seconds default
|
|
13562
13562
|
sound: z2.boolean().optional(),
|
|
13563
13563
|
pseudo: z2.boolean().optional()
|
|
@@ -15242,7 +15242,7 @@ async function renderHero2() {
|
|
|
15242
15242
|
// package.json
|
|
15243
15243
|
var package_default = {
|
|
15244
15244
|
name: "lingo.dev",
|
|
15245
|
-
version: "0.
|
|
15245
|
+
version: "0.122.0",
|
|
15246
15246
|
description: "Lingo.dev CLI",
|
|
15247
15247
|
private: false,
|
|
15248
15248
|
repository: {
|
|
@@ -15371,10 +15371,10 @@ var package_default = {
|
|
|
15371
15371
|
author: "",
|
|
15372
15372
|
license: "Apache-2.0",
|
|
15373
15373
|
dependencies: {
|
|
15374
|
-
"@ai-sdk/anthropic": "
|
|
15375
|
-
"@ai-sdk/google": "
|
|
15376
|
-
"@ai-sdk/mistral": "
|
|
15377
|
-
"@ai-sdk/openai": "
|
|
15374
|
+
"@ai-sdk/anthropic": "3.0.9",
|
|
15375
|
+
"@ai-sdk/google": "3.0.6",
|
|
15376
|
+
"@ai-sdk/mistral": "3.0.5",
|
|
15377
|
+
"@ai-sdk/openai": "3.0.7",
|
|
15378
15378
|
"@babel/generator": "7.28.5",
|
|
15379
15379
|
"@babel/parser": "7.28.5",
|
|
15380
15380
|
"@babel/traverse": "7.28.5",
|
|
@@ -15392,10 +15392,10 @@ var package_default = {
|
|
|
15392
15392
|
"@lingo.dev/_spec": "workspace:*",
|
|
15393
15393
|
"@markdoc/markdoc": "0.5.4",
|
|
15394
15394
|
"@modelcontextprotocol/sdk": "1.22.0",
|
|
15395
|
-
"@openrouter/ai-sdk-provider": "0.
|
|
15395
|
+
"@openrouter/ai-sdk-provider": "6.0.0-alpha.1",
|
|
15396
15396
|
"@paralleldrive/cuid2": "2.2.2",
|
|
15397
15397
|
"@types/ejs": "3.1.5",
|
|
15398
|
-
ai: "
|
|
15398
|
+
ai: "6.0.25",
|
|
15399
15399
|
bitbucket: "2.12.0",
|
|
15400
15400
|
chalk: "5.6.2",
|
|
15401
15401
|
chokidar: "4.0.3",
|
|
@@ -15442,7 +15442,7 @@ var package_default = {
|
|
|
15442
15442
|
"node-webvtt": "1.9.4",
|
|
15443
15443
|
"object-hash": "3.0.0",
|
|
15444
15444
|
octokit: "4.0.2",
|
|
15445
|
-
"ollama-ai-provider": "
|
|
15445
|
+
"ollama-ai-provider-v2": "2.0.0",
|
|
15446
15446
|
open: "10.2.0",
|
|
15447
15447
|
ora: "8.1.1",
|
|
15448
15448
|
"p-limit": "6.2.0",
|
|
@@ -15469,7 +15469,7 @@ var package_default = {
|
|
|
15469
15469
|
xml2js: "0.6.2",
|
|
15470
15470
|
xpath: "0.0.34",
|
|
15471
15471
|
yaml: "2.8.1",
|
|
15472
|
-
zod: "
|
|
15472
|
+
zod: "4.1.12"
|
|
15473
15473
|
},
|
|
15474
15474
|
devDependencies: {
|
|
15475
15475
|
"@types/babel__generator": "7.27.0",
|