gtx-cli 2.0.24 → 2.1.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/CHANGELOG.md CHANGED
@@ -1,5 +1,16 @@
1
1
  # gtx-cli
2
2
 
3
+ ## 2.1.0
4
+
5
+ ### Minor Changes
6
+
7
+ - [#556](https://github.com/generaltranslation/gt/pull/556) [`c52d896`](https://github.com/generaltranslation/gt/commit/c52d896f83fb4f6e58921286320a524885c8a52d) Thanks [@fernando-aviles](https://github.com/fernando-aviles)! - Adding modelProvider field to gt.config
8
+
9
+ ### Patch Changes
10
+
11
+ - Updated dependencies [[`c52d896`](https://github.com/generaltranslation/gt/commit/c52d896f83fb4f6e58921286320a524885c8a52d)]:
12
+ - generaltranslation@7.3.0
13
+
3
14
  ## 2.0.24
4
15
 
5
16
  ### Patch Changes
@@ -21,6 +21,7 @@ export async function sendFiles(files, options) {
21
21
  sourceLocale: options.defaultLocale,
22
22
  targetLocales: options.locales,
23
23
  _versionId: options._versionId,
24
+ modelProvider: options.modelProvider,
24
25
  });
25
26
  // Handle version ID response (for async processing)
26
27
  const { data, message, locales, translations } = responseData;
@@ -20,6 +20,7 @@ export async function sendUpdates(updates, options, library) {
20
20
  version: options.version,
21
21
  description: options.description,
22
22
  requireApproval: options.requireApproval,
23
+ modelProvider: options.modelProvider,
23
24
  });
24
25
  const { versionId, message, locales, projectSettings } = responseData;
25
26
  spinner.stop(chalk.green('Sent updates'));
@@ -13,6 +13,7 @@ export type UploadData = {
13
13
  translations: FileUpload[];
14
14
  }[];
15
15
  sourceLocale: string;
16
+ modelProvider?: string;
16
17
  };
17
18
  /**
18
19
  * Uploads multiple files to the API
@@ -22,6 +22,7 @@ export async function uploadFiles(files, options) {
22
22
  translations: file.translations,
23
23
  })),
24
24
  sourceLocale: options.defaultLocale,
25
+ ...(options.modelProvider && { modelProvider: options.modelProvider }),
25
26
  };
26
27
  try {
27
28
  const response = await fetch(`${options.baseUrl}/v1/project/files/upload`, {
@@ -98,6 +98,7 @@ export type Settings = {
98
98
  src: string[];
99
99
  framework?: SupportedFrameworks;
100
100
  options?: AdditionalOptions;
101
+ modelProvider?: string;
101
102
  };
102
103
  export type AdditionalOptions = {
103
104
  jsonSchema?: {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "gtx-cli",
3
- "version": "2.0.24",
3
+ "version": "2.1.0",
4
4
  "main": "dist/index.js",
5
5
  "bin": "dist/main.js",
6
6
  "files": [
@@ -87,7 +87,7 @@
87
87
  "esbuild": "^0.25.4",
88
88
  "fast-glob": "^3.3.3",
89
89
  "form-data": "^4.0.4",
90
- "generaltranslation": "^7.1.4",
90
+ "generaltranslation": "^7.3.0",
91
91
  "json-pointer": "^0.6.2",
92
92
  "jsonpath-plus": "^10.3.0",
93
93
  "jsonpointer": "^5.0.1",