gtx-cli 2.6.13 → 2.6.14
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,13 @@
|
|
|
1
1
|
# gtx-cli
|
|
2
2
|
|
|
3
|
+
## 2.6.14
|
|
4
|
+
|
|
5
|
+
### Patch Changes
|
|
6
|
+
|
|
7
|
+
- [#996](https://github.com/generaltranslation/gt/pull/996) [`13714ba`](https://github.com/generaltranslation/gt/commit/13714ba951bd56e7b897e81ee529661da3dec01a) Thanks [@brian-lou](https://github.com/brian-lou)! - Change pino transport
|
|
8
|
+
|
|
9
|
+
- [#998](https://github.com/generaltranslation/gt/pull/998) [`9661270`](https://github.com/generaltranslation/gt/commit/966127076152d8a6d911324947942a05bd31cf6e) Thanks [@brian-lou](https://github.com/brian-lou)! - Disable branching by default
|
|
10
|
+
|
|
3
11
|
## 2.6.13
|
|
4
12
|
|
|
5
13
|
### Patch Changes
|
package/dist/cli/flags.js
CHANGED
|
@@ -37,7 +37,6 @@ export function attachTranslateFlags(command) {
|
|
|
37
37
|
.option('--branch <branch>', 'Specify a custom branch to use for translations')
|
|
38
38
|
.option('--disable-branch-detection', 'Disable additional branch detection and optimizations and use the manually specified branch', false)
|
|
39
39
|
.option('--enable-branching', 'Enable branching for the project')
|
|
40
|
-
.option('--no-enable-branching', 'Disable branching for the project')
|
|
41
40
|
.option('--remote-name <name>', 'Specify a custom remote name to use for branch detection', DEFAULT_GIT_REMOTE_NAME);
|
|
42
41
|
return command;
|
|
43
42
|
}
|
|
@@ -176,7 +176,7 @@ export async function generateSettings(flags, cwd = process.cwd()) {
|
|
|
176
176
|
// Add branch options if not provided
|
|
177
177
|
const branchOptions = mergedOptions.branchOptions || {};
|
|
178
178
|
branchOptions.enabled =
|
|
179
|
-
flags.enableBranching ?? gtConfig.branchOptions?.enabled ??
|
|
179
|
+
flags.enableBranching ?? gtConfig.branchOptions?.enabled ?? false;
|
|
180
180
|
branchOptions.currentBranch =
|
|
181
181
|
flags.branch ?? gtConfig.branchOptions?.currentBranch ?? undefined;
|
|
182
182
|
branchOptions.autoDetectBranches = flags.disableBranchDetection
|
package/dist/console/logger.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import chalk from 'chalk';
|
|
2
2
|
import { randomUUID } from 'node:crypto';
|
|
3
|
-
import { pino,
|
|
3
|
+
import { pino, destination } from 'pino';
|
|
4
4
|
import { log as clackLog, spinner, progress, intro, outro, } from '@clack/prompts';
|
|
5
5
|
// Mock spinner that logs to console instead of updating terminal UI
|
|
6
6
|
class MockSpinner {
|
|
@@ -89,27 +89,15 @@ class Logger {
|
|
|
89
89
|
process.exit(1);
|
|
90
90
|
}
|
|
91
91
|
this.logFormat = format;
|
|
92
|
-
|
|
93
|
-
//
|
|
92
|
+
// Console output (stdout) - only for JSON format
|
|
93
|
+
// For 'default' format, we use @clack/prompts directly
|
|
94
94
|
if (format === 'json') {
|
|
95
|
-
// JSON formatted console output
|
|
96
|
-
transports.push({
|
|
97
|
-
level: logLevel,
|
|
98
|
-
target: 'pino/file',
|
|
99
|
-
options: { destination: 1 }, // stdout
|
|
100
|
-
});
|
|
101
|
-
}
|
|
102
|
-
// For 'default' format, we don't add a console transport - we'll use @clack/prompts directly
|
|
103
|
-
// Create console logger if we have console transports
|
|
104
|
-
if (transports.length > 0) {
|
|
105
95
|
this.pinoLogger = pino({
|
|
106
96
|
level: logLevel,
|
|
107
97
|
mixin: () => ({
|
|
108
98
|
logId: randomUUID(),
|
|
109
99
|
}),
|
|
110
|
-
},
|
|
111
|
-
targets: transports,
|
|
112
|
-
}));
|
|
100
|
+
}, destination(1));
|
|
113
101
|
}
|
|
114
102
|
// File output (if specified) - always JSON format
|
|
115
103
|
if (logFile) {
|
|
@@ -118,15 +106,7 @@ class Logger {
|
|
|
118
106
|
mixin: () => ({
|
|
119
107
|
logId: randomUUID(),
|
|
120
108
|
}),
|
|
121
|
-
},
|
|
122
|
-
targets: [
|
|
123
|
-
{
|
|
124
|
-
level: logLevel,
|
|
125
|
-
target: 'pino/file',
|
|
126
|
-
options: { destination: logFile },
|
|
127
|
-
},
|
|
128
|
-
],
|
|
129
|
-
}));
|
|
109
|
+
}, destination(logFile));
|
|
130
110
|
}
|
|
131
111
|
}
|
|
132
112
|
static getInstance() {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
export declare const PACKAGE_VERSION = "2.6.
|
|
1
|
+
export declare const PACKAGE_VERSION = "2.6.14";
|
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
// This file is auto-generated. Do not edit manually.
|
|
2
|
-
export const PACKAGE_VERSION = '2.6.
|
|
2
|
+
export const PACKAGE_VERSION = '2.6.14';
|
|
@@ -84,6 +84,7 @@ export class BranchStep extends WorkflowStep {
|
|
|
84
84
|
}
|
|
85
85
|
catch (error) {
|
|
86
86
|
if (error instanceof ApiError && error.code === 403) {
|
|
87
|
+
logger.warn('To enable translation branching, please upgrade your plan. Falling back to default branch.');
|
|
87
88
|
// retry with default branch
|
|
88
89
|
try {
|
|
89
90
|
const createBranchResult = await this.gt.createBranch({
|