duojie-helper 0.2.2 → 0.2.3

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/bin/cli.js CHANGED
@@ -11,7 +11,7 @@ const program = new Command();
11
11
  program
12
12
  .name('duojie')
13
13
  .description('🎮 Duojie API 一键配置助手 - 支持主流 AI 编程工具')
14
- .version('0.2.0');
14
+ .version('0.2.3');
15
15
 
16
16
  // 默认命令 - 交互式配置
17
17
  program
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "duojie-helper",
3
- "version": "0.2.2",
3
+ "version": "0.2.3",
4
4
  "description": "Duojie API 一键配置助手 - 支持 Claude Code, OpenClaw, Cursor, Cline 等主流 AI 编程工具",
5
5
  "type": "module",
6
6
  "bin": {
package/src/index.js CHANGED
@@ -113,37 +113,37 @@ const toolConfigurators = {
113
113
  const toolInfo = {
114
114
  claude: {
115
115
  name: 'Claude Code',
116
- description: 'Anthropic 官方 CLI 工具 (自动配置)',
116
+ description: 'Anthropic 官方 CLI 工具(自动配置)',
117
117
  configPath: '~/.claude/settings.json',
118
118
  },
119
119
  openclaw: {
120
120
  name: 'OpenClaw / Moltbot',
121
- description: '多平台 AI 助手网关 (自动配置)',
121
+ description: '多平台 AI 助手网关(自动配置)',
122
122
  configPath: '~/.openclaw/openclaw.json',
123
123
  },
124
124
  opencode: {
125
125
  name: 'OpenCode',
126
- description: '终端 AI 编码助手 (自动配置)',
126
+ description: '终端 AI 编码助手(自动配置)',
127
127
  configPath: '~/.config/opencode/opencode.json',
128
128
  },
129
129
  continue: {
130
130
  name: 'Continue',
131
- description: 'VS Code/JetBrains AI 插件 (自动配置)',
131
+ description: 'VS Code/JetBrains AI 插件(自动配置)',
132
132
  configPath: '~/.continue/config.json',
133
133
  },
134
134
  codex: {
135
135
  name: 'Codex CLI',
136
- description: 'OpenAI Codex 命令行工具 (自动配置)',
136
+ description: 'OpenAI Codex 命令行工具(自动配置)',
137
137
  configPath: '~/.codex/config.toml',
138
138
  },
139
139
  cursor: {
140
140
  name: 'Cursor',
141
- description: 'AI 代码编辑器 (需手动配置,需 Pro 订阅)',
141
+ description: 'AI 代码编辑器(需手动配置,需 Pro 订阅)',
142
142
  configPath: 'Cursor Settings → Models',
143
143
  },
144
144
  cline: {
145
145
  name: 'Cline',
146
- description: 'VS Code AI 编程插件 (需手动配置)',
146
+ description: 'VS Code AI 编程插件(需手动配置)',
147
147
  configPath: 'Cline 插件设置',
148
148
  },
149
149
  };
@@ -151,7 +151,7 @@ configureClaudeCode.checkStatus = async function() {
151
151
  } else if (settings.env?.ANTHROPIC_API_KEY || settings.env?.ANTHROPIC_AUTH_TOKEN) {
152
152
  return {
153
153
  configured: true,
154
- message: '已配置 (非 Duojie)',
154
+ message: '已配置(非 Duojie',
155
155
  };
156
156
  }
157
157
  } catch {
@@ -53,7 +53,7 @@ ${chalk.cyan('步骤 4:')} 填入以下配置:
53
53
  ${chalk.cyan('步骤 5:')} 可选配置:
54
54
  • ${chalk.green('Max Tokens:')} 8192 (推荐)
55
55
  • Context Window Size: 200000
56
- • 取消勾选 "Support Images" (如果模型不支持)
56
+ • 取消勾选 "Support Images"(如果模型不支持)
57
57
 
58
58
  ${chalk.gray('提示: 配置完成后即可在 Cline 中使用 Duojie API')}
59
59
  `;
@@ -82,7 +82,7 @@ configureCline.checkStatus = async function() {
82
82
  if (await fs.pathExists(paths.globalStorageDir)) {
83
83
  return {
84
84
  configured: true,
85
- message: 'Cline 插件已安装 (配置状态需在 VS Code 中查看)',
85
+ message: 'Cline 插件已安装(配置状态需在 VS Code 中查看)',
86
86
  };
87
87
  }
88
88
 
@@ -228,7 +228,7 @@ configureCodex.checkStatus = async function() {
228
228
  if (content.includes('model_providers.duojie') || content.includes('duojie')) {
229
229
  return { configured: true, message: '已配置 Duojie API' };
230
230
  } else if (content.includes('model_provider')) {
231
- return { configured: true, message: '已配置 (非 Duojie)' };
231
+ return { configured: true, message: '已配置(非 Duojie' };
232
232
  }
233
233
  } catch {}
234
234
  }
@@ -124,7 +124,7 @@ configureContinue.checkStatus = async function() {
124
124
  if (config._duojie?.configured) {
125
125
  return { configured: true, message: '已配置 Duojie API' };
126
126
  } else if (config.models?.length > 0) {
127
- return { configured: true, message: '已配置 (非 Duojie)' };
127
+ return { configured: true, message: '已配置(非 Duojie' };
128
128
  }
129
129
  } catch {}
130
130
  }
@@ -46,14 +46,14 @@ ${chalk.cyan('步骤 3:')} 填入以下配置:
46
46
  ${chalk.green('Protocol:')} OpenAI
47
47
  ${chalk.green('OpenAI API Key:')} ${apiKey}
48
48
  ${chalk.green('Override OpenAI Base URL:')} ${baseUrl}
49
- ${chalk.green('Model Name:')} 输入模型名称 (注意大小写)
49
+ ${chalk.green('Model Name:')} 输入模型名称(注意大小写)
50
50
  例如: claude-sonnet-4-5-20250929
51
51
  或: gpt-4o
52
52
 
53
53
  ${chalk.cyan('步骤 4:')} 点击保存,然后在模型列表中选择刚添加的模型
54
54
 
55
55
  ${chalk.cyan('可选配置:')}
56
- ${chalk.green('Max Tokens:')} 8192 (推荐)
56
+ ${chalk.green('Max Tokens:')} 8192(推荐)
57
57
 
58
58
  ${chalk.gray('提示: 如果遇到 "The model does not work with your current plan" 错误,')}
59
59
  ${chalk.gray(' 说明您的 Cursor 订阅不支持自定义模型')}
@@ -62,7 +62,7 @@ ${chalk.gray(' 说明您的 Cursor 订阅不支持自定义模型')}
62
62
  return {
63
63
  success: true,
64
64
  manual: true,
65
- message: '需要手动配置 (需 Cursor Pro)',
65
+ message: '需要手动配置(需 Cursor Pro',
66
66
  instructions: instructions,
67
67
  configInfo: {
68
68
  protocol: 'OpenAI',
@@ -81,7 +81,7 @@ configureCursor.checkStatus = async function() {
81
81
  if (await fs.pathExists(paths.configDir)) {
82
82
  return {
83
83
  configured: true,
84
- message: 'Cursor 已安装 (配置状态需在 Cursor 中查看)',
84
+ message: 'Cursor 已安装(配置状态需在 Cursor 中查看)',
85
85
  };
86
86
  }
87
87
 
@@ -232,7 +232,7 @@ configureOpenClaw.checkStatus = async function() {
232
232
  } else if (config.models?.providers) {
233
233
  return {
234
234
  configured: true,
235
- message: '已配置 (非 Duojie)',
235
+ message: '已配置(非 Duojie',
236
236
  };
237
237
  }
238
238
  } catch {
@@ -198,7 +198,7 @@ configureOpenCode.checkStatus = async function() {
198
198
  } else if (config.provider && Object.keys(config.provider).length > 0) {
199
199
  return {
200
200
  configured: true,
201
- message: '已配置 (非 Duojie)',
201
+ message: '已配置(非 Duojie',
202
202
  };
203
203
  }
204
204
  } catch {