lingo.dev 0.122.1 → 0.123.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.mjs CHANGED
@@ -771,9 +771,10 @@ import { checkbox as checkbox2, confirm as confirm3, input } from "@inquirer/pro
771
771
 
772
772
  // src/cli/utils/find-locale-paths.ts
773
773
  import path3 from "path";
774
- import { glob } from "glob";
774
+ import * as pkg from "glob";
775
775
  import _2 from "lodash";
776
776
  import { resolveLocaleCode } from "@lingo.dev/_spec";
777
+ var { glob } = pkg;
777
778
  function findLocaleFiles(bucket) {
778
779
  switch (bucket) {
779
780
  case "json":
@@ -1412,10 +1413,11 @@ import Ora7 from "ora";
1412
1413
  // src/cli/utils/buckets.ts
1413
1414
  import _5 from "lodash";
1414
1415
  import path10 from "path";
1415
- import { glob as glob2 } from "glob";
1416
+ import * as pkg2 from "glob";
1416
1417
  import {
1417
1418
  resolveOverriddenLocale
1418
1419
  } from "@lingo.dev/_spec";
1420
+ var { glob: glob2 } = pkg2;
1419
1421
  function getBuckets(i18nConfig) {
1420
1422
  const result = Object.entries(i18nConfig.buckets).map(
1421
1423
  ([bucketType, bucketEntry]) => {
@@ -10989,7 +10991,7 @@ function withExponentialBackoff(fn, maxAttempts = 3, baseDelay = 1e3) {
10989
10991
  }
10990
10992
 
10991
10993
  // src/cli/utils/observability.ts
10992
- import pkg from "node-machine-id";
10994
+ import pkg3 from "node-machine-id";
10993
10995
  import https from "https";
10994
10996
 
10995
10997
  // src/cli/utils/repository-id.ts
@@ -11069,7 +11071,7 @@ function parseGitUrl(url) {
11069
11071
  }
11070
11072
 
11071
11073
  // src/cli/utils/observability.ts
11072
- var { machineIdSync } = pkg;
11074
+ var { machineIdSync } = pkg3;
11073
11075
  var POSTHOG_API_KEY = "phc_eR0iSoQufBxNY36k0f0T15UvHJdTfHlh8rJcxsfhfXk";
11074
11076
  var POSTHOG_HOST = "eu.i.posthog.com";
11075
11077
  var POSTHOG_PATH = "/i/v0/e/";
@@ -11621,7 +11623,8 @@ var i18n_default = new Command14().command("i18n").description(
11621
11623
  sourceData,
11622
11624
  processableData,
11623
11625
  targetLocale,
11624
- targetData
11626
+ // When --force is used, exclude previous translations from reference to ensure fresh translations
11627
+ targetData: flags.force ? {} : targetData
11625
11628
  },
11626
11629
  (progress, sourceChunk, processedChunk) => {
11627
11630
  bucketOra.text = `[${sourceLocale} -> ${targetLocale}] [${Object.keys(processableData).length} entries] (${progress}%) AI localization in progress...`;
@@ -13263,7 +13266,8 @@ function createWorkerTask(args) {
13263
13266
  sourceLocale: assignedTask.sourceLocale,
13264
13267
  targetLocale: assignedTask.targetLocale,
13265
13268
  sourceData,
13266
- targetData,
13269
+ // When --force is used, exclude previous translations from reference to ensure fresh translations
13270
+ targetData: args.ctx.flags.force ? {} : targetData,
13267
13271
  processableData,
13268
13272
  hints: relevantHints
13269
13273
  },
@@ -15187,7 +15191,7 @@ async function renderHero2() {
15187
15191
  // package.json
15188
15192
  var package_default = {
15189
15193
  name: "lingo.dev",
15190
- version: "0.122.1",
15194
+ version: "0.123.0",
15191
15195
  description: "Lingo.dev CLI",
15192
15196
  private: false,
15193
15197
  repository: {
@@ -15295,7 +15299,7 @@ var package_default = {
15295
15299
  }
15296
15300
  },
15297
15301
  bin: {
15298
- "lingo.dev": "./bin/cli.mjs"
15302
+ lingo: "./bin/cli.mjs"
15299
15303
  },
15300
15304
  files: [
15301
15305
  "bin",