daodou-command 1.4.1 → 1.4.2
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/.idea/workspace.xml +1 -1
- package/CHANGELOG.md +7 -1
- package/lib/commands/lang.js +0 -2
- package/lib/translation/TranslationService.js +0 -19
- package/lib/utils/translation.js +0 -18
- package/package.json +1 -1
package/.idea/workspace.xml
CHANGED
|
@@ -62,7 +62,7 @@
|
|
|
62
62
|
<option name="number" value="Default" />
|
|
63
63
|
<option name="presentableId" value="Default" />
|
|
64
64
|
<updated>1758879086844</updated>
|
|
65
|
-
<workItem from="1758879088110" duration="
|
|
65
|
+
<workItem from="1758879088110" duration="1336000" />
|
|
66
66
|
</task>
|
|
67
67
|
<servers />
|
|
68
68
|
</component>
|
package/CHANGELOG.md
CHANGED
|
@@ -5,7 +5,13 @@
|
|
|
5
5
|
格式基于 [Keep a Changelog](https://keepachangelog.com/zh-CN/1.0.0/),
|
|
6
6
|
并且此项目遵循 [语义化版本](https://semver.org/lang/zh-CN/)。
|
|
7
7
|
|
|
8
|
-
|
|
8
|
+
|
|
9
|
+
## [1.4.2] - 2025-09-26
|
|
10
|
+
|
|
11
|
+
### 修复
|
|
12
|
+
- 清理代理功能相关代码,移除已废弃的代理统计信息输出
|
|
13
|
+
|
|
14
|
+
## [1.4.1] - 2025-09-26
|
|
9
15
|
|
|
10
16
|
### 修复
|
|
11
17
|
- 移除翻译服务初始化时的冗余输出信息,提升用户体验
|
package/lib/commands/lang.js
CHANGED
|
@@ -150,8 +150,6 @@ class LangCommand {
|
|
|
150
150
|
console.log(chalk.yellow(` ⏭️ 跳过: ${skipCount} 个语言`));
|
|
151
151
|
console.log(chalk.red(` ❌ 失败: ${failCount} 个语言`));
|
|
152
152
|
|
|
153
|
-
// 显示代理统计信息
|
|
154
|
-
this.translationService.showProxyStats();
|
|
155
153
|
|
|
156
154
|
console.log(chalk.blue('\n📋 翻译结果汇总:'));
|
|
157
155
|
console.log(chalk.gray(`原文: "${finalValue}"`));
|
|
@@ -184,25 +184,6 @@ class TranslationService {
|
|
|
184
184
|
return status.sort((a, b) => a.priority - b.priority);
|
|
185
185
|
}
|
|
186
186
|
|
|
187
|
-
/**
|
|
188
|
-
* 获取代理统计信息(已禁用)
|
|
189
|
-
* @returns {object} 代理统计信息
|
|
190
|
-
*/
|
|
191
|
-
getProxyStats() {
|
|
192
|
-
return {
|
|
193
|
-
totalProxies: 0,
|
|
194
|
-
currentIndex: 0,
|
|
195
|
-
hasProxies: false,
|
|
196
|
-
message: '代理功能已禁用,直接使用微软翻译'
|
|
197
|
-
};
|
|
198
|
-
}
|
|
199
|
-
|
|
200
|
-
/**
|
|
201
|
-
* 重置代理列表(已禁用)
|
|
202
|
-
*/
|
|
203
|
-
async resetProxies() {
|
|
204
|
-
console.log(chalk.yellow('代理功能已禁用,直接使用微软翻译'));
|
|
205
|
-
}
|
|
206
187
|
}
|
|
207
188
|
|
|
208
189
|
module.exports = TranslationService;
|
package/lib/utils/translation.js
CHANGED
|
@@ -114,24 +114,6 @@ class TranslationService {
|
|
|
114
114
|
return languageNames[langCode] || langCode.toUpperCase();
|
|
115
115
|
}
|
|
116
116
|
|
|
117
|
-
/**
|
|
118
|
-
* 获取代理统计信息
|
|
119
|
-
* @returns {Object} 统计信息
|
|
120
|
-
*/
|
|
121
|
-
getProxyStats() {
|
|
122
|
-
return this.translationService.getProxyStats();
|
|
123
|
-
}
|
|
124
|
-
|
|
125
|
-
/**
|
|
126
|
-
* 显示代理统计信息
|
|
127
|
-
*/
|
|
128
|
-
showProxyStats() {
|
|
129
|
-
const stats = this.getProxyStats();
|
|
130
|
-
console.log(chalk.blue('\n📊 代理服务器统计:'));
|
|
131
|
-
console.log(chalk.gray(` 总代理数: ${stats.totalProxies}`));
|
|
132
|
-
console.log(chalk.gray(` 当前索引: ${stats.currentIndex}`));
|
|
133
|
-
console.log(chalk.gray(` 有代理: ${stats.hasProxies ? '是' : '否'}`));
|
|
134
|
-
}
|
|
135
117
|
|
|
136
118
|
/**
|
|
137
119
|
* 获取引擎状态
|