ccg-workflow 1.7.8 → 1.7.10
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/README.md +32 -2
- package/bin/codeagent-wrapper-darwin-amd64 +0 -0
- package/bin/codeagent-wrapper-darwin-arm64 +0 -0
- package/bin/codeagent-wrapper-linux-amd64 +0 -0
- package/bin/codeagent-wrapper-linux-arm64 +0 -0
- package/bin/codeagent-wrapper-windows-amd64.exe +0 -0
- package/bin/codeagent-wrapper-windows-arm64.exe +0 -0
- package/dist/cli.mjs +1 -1
- package/dist/index.mjs +1 -1
- package/dist/shared/{ccg-workflow.CSFmksBD.mjs → ccg-workflow.PDaIyvrx.mjs} +56 -3
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -307,6 +307,8 @@ Windows:
|
|
|
307
307
|
<details>
|
|
308
308
|
<summary><strong>Q6: 如何卸载?</strong></summary>
|
|
309
309
|
|
|
310
|
+
**方式 1:交互式卸载**
|
|
311
|
+
|
|
310
312
|
```bash
|
|
311
313
|
npx ccg-workflow
|
|
312
314
|
# 选择 "卸载工作流"
|
|
@@ -316,9 +318,37 @@ npx ccg-workflow
|
|
|
316
318
|
- `~/.claude/commands/ccg/` - 命令文件
|
|
317
319
|
- `~/.claude/agents/ccg/` - 子智能体
|
|
318
320
|
- `~/.claude/skills/` - skills
|
|
319
|
-
- `~/.claude/bin/codeagent-wrapper
|
|
321
|
+
- `~/.claude/bin/codeagent-wrapper*` - 二进制文件
|
|
320
322
|
- `~/.claude/.ccg/` - 配置目录(可选保留)
|
|
321
323
|
|
|
324
|
+
**方式 2:手动清理**
|
|
325
|
+
|
|
326
|
+
```bash
|
|
327
|
+
# 删除所有安装文件
|
|
328
|
+
rm -rf ~/.claude/commands/ccg
|
|
329
|
+
rm -rf ~/.claude/agents/ccg
|
|
330
|
+
rm -rf ~/.claude/skills/multi-model-collaboration
|
|
331
|
+
rm -rf ~/.claude/bin/codeagent-wrapper*
|
|
332
|
+
rm -rf ~/.claude/.ccg
|
|
333
|
+
|
|
334
|
+
# 清理 MCP 配置(如果安装了 ace-tool)
|
|
335
|
+
# 手动编辑 ~/.claude.json 删除 ace-tool 相关配置
|
|
336
|
+
```
|
|
337
|
+
|
|
338
|
+
**⚠️ 注意:npx 缓存问题**
|
|
339
|
+
|
|
340
|
+
`ccg-workflow` 通过 npx 运行,npx 会缓存已下载的包。如果卸载后重新安装仍使用旧版本,需要清理 npx 缓存:
|
|
341
|
+
|
|
342
|
+
```bash
|
|
343
|
+
# 清理 npx 缓存(强制下载最新版本)
|
|
344
|
+
npx clear-npx-cache
|
|
345
|
+
# 或
|
|
346
|
+
rm -rf ~/.npm/_npx
|
|
347
|
+
|
|
348
|
+
# 然后重新安装
|
|
349
|
+
npx ccg-workflow@latest
|
|
350
|
+
```
|
|
351
|
+
|
|
322
352
|
</details>
|
|
323
353
|
|
|
324
354
|
---
|
|
@@ -352,7 +382,7 @@ Copyright (c) 2025 fengshao1227
|
|
|
352
382
|
|
|
353
383
|
<div align="center">
|
|
354
384
|
|
|
355
|
-
**版本**: v1.7.
|
|
385
|
+
**版本**: v1.7.10 | **最后更新**: 2026-01-09
|
|
356
386
|
|
|
357
387
|
Made with ❤️ by the CCG Community
|
|
358
388
|
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
package/dist/cli.mjs
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
2
|
import cac from 'cac';
|
|
3
3
|
import ansis from 'ansis';
|
|
4
|
-
import { y as diagnoseMcpConfig, z as isWindows, A as readClaudeCodeConfig, B as fixWindowsMcpConfig, C as writeClaudeCodeConfig, r as readCcgConfig, b as initI18n, s as showMainMenu, i as init, D as configMcp, E as version, a as i18n } from './shared/ccg-workflow.
|
|
4
|
+
import { y as diagnoseMcpConfig, z as isWindows, A as readClaudeCodeConfig, B as fixWindowsMcpConfig, C as writeClaudeCodeConfig, r as readCcgConfig, b as initI18n, s as showMainMenu, i as init, D as configMcp, E as version, a as i18n } from './shared/ccg-workflow.PDaIyvrx.mjs';
|
|
5
5
|
import 'inquirer';
|
|
6
6
|
import 'node:os';
|
|
7
7
|
import 'pathe';
|
package/dist/index.mjs
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
export { c as changeLanguage, v as checkForUpdates, x as compareVersions, d as createDefaultConfig, e as createDefaultRouting, g as getCcgDir, f as getConfigPath, q as getCurrentVersion, t as getLatestVersion, j as getWorkflowById, h as getWorkflowConfigs, a as i18n, i as init, b as initI18n, l as installAceTool, k as installWorkflows, o as migrateToV1_4_0, p as needsMigration, r as readCcgConfig, s as showMainMenu, n as uninstallAceTool, m as uninstallWorkflows, u as update, w as writeCcgConfig } from './shared/ccg-workflow.
|
|
1
|
+
export { c as changeLanguage, v as checkForUpdates, x as compareVersions, d as createDefaultConfig, e as createDefaultRouting, g as getCcgDir, f as getConfigPath, q as getCurrentVersion, t as getLatestVersion, j as getWorkflowById, h as getWorkflowConfigs, a as i18n, i as init, b as initI18n, l as installAceTool, k as installWorkflows, o as migrateToV1_4_0, p as needsMigration, r as readCcgConfig, s as showMainMenu, n as uninstallAceTool, m as uninstallWorkflows, u as update, w as writeCcgConfig } from './shared/ccg-workflow.PDaIyvrx.mjs';
|
|
2
2
|
import 'ansis';
|
|
3
3
|
import 'inquirer';
|
|
4
4
|
import 'node:os';
|
|
@@ -10,7 +10,7 @@ import { parse, stringify } from 'smol-toml';
|
|
|
10
10
|
import { exec } from 'node:child_process';
|
|
11
11
|
import { promisify } from 'node:util';
|
|
12
12
|
|
|
13
|
-
const version = "1.7.
|
|
13
|
+
const version = "1.7.10";
|
|
14
14
|
|
|
15
15
|
function isWindows() {
|
|
16
16
|
return process.platform === "win32";
|
|
@@ -344,11 +344,24 @@ function injectConfigVariables(content, config) {
|
|
|
344
344
|
processed = processed.replace(/\{\{ROUTING_MODE\}\}/g, routingMode);
|
|
345
345
|
return processed;
|
|
346
346
|
}
|
|
347
|
+
function convertToGitBashPath(windowsPath) {
|
|
348
|
+
if (!isWindows()) {
|
|
349
|
+
return windowsPath;
|
|
350
|
+
}
|
|
351
|
+
let path = windowsPath.replace(/\\/g, "/");
|
|
352
|
+
path = path.replace(/^([A-Z]):/i, (_, drive) => `/${drive.toLowerCase()}`);
|
|
353
|
+
return path;
|
|
354
|
+
}
|
|
347
355
|
function replaceHomePathsInTemplate(content, installDir) {
|
|
348
356
|
const userHome = homedir();
|
|
349
357
|
const ccgDir = join(installDir, ".ccg");
|
|
350
|
-
|
|
351
|
-
|
|
358
|
+
const binDir = join(installDir, "bin");
|
|
359
|
+
const userHomePath = convertToGitBashPath(userHome);
|
|
360
|
+
const ccgDirPath = convertToGitBashPath(ccgDir);
|
|
361
|
+
const binDirPath = convertToGitBashPath(binDir);
|
|
362
|
+
let processed = content.replace(/~\/\.claude\/\.ccg/g, ccgDirPath);
|
|
363
|
+
processed = processed.replace(/~\/\.claude\/bin/g, binDirPath);
|
|
364
|
+
processed = processed.replace(/~\//g, `${userHomePath}/`);
|
|
352
365
|
return processed;
|
|
353
366
|
}
|
|
354
367
|
async function installWorkflows(workflowIds, installDir, force = false, config) {
|
|
@@ -1693,6 +1706,20 @@ async function performUpdate(fromVersion, toVersion, isNewVersion) {
|
|
|
1693
1706
|
console.log();
|
|
1694
1707
|
let spinner = ora("\u6B63\u5728\u4E0B\u8F7D\u6700\u65B0\u7248\u672C...").start();
|
|
1695
1708
|
try {
|
|
1709
|
+
if (process.platform === "win32") {
|
|
1710
|
+
spinner.text = "\u6B63\u5728\u6E05\u7406 npx \u7F13\u5B58...";
|
|
1711
|
+
try {
|
|
1712
|
+
await execAsync("npx clear-npx-cache", { timeout: 1e4 });
|
|
1713
|
+
} catch {
|
|
1714
|
+
const npxCachePath = join(homedir(), ".npm", "_npx");
|
|
1715
|
+
try {
|
|
1716
|
+
const fs = await import('fs-extra');
|
|
1717
|
+
await fs.remove(npxCachePath);
|
|
1718
|
+
} catch {
|
|
1719
|
+
}
|
|
1720
|
+
}
|
|
1721
|
+
}
|
|
1722
|
+
spinner.text = "\u6B63\u5728\u4E0B\u8F7D\u6700\u65B0\u7248\u672C...";
|
|
1696
1723
|
await execAsync(`npx --yes ccg-workflow@latest --version`, { timeout: 6e4 });
|
|
1697
1724
|
spinner.succeed("\u6700\u65B0\u7248\u672C\u4E0B\u8F7D\u5B8C\u6210");
|
|
1698
1725
|
} catch (error) {
|
|
@@ -1700,6 +1727,32 @@ async function performUpdate(fromVersion, toVersion, isNewVersion) {
|
|
|
1700
1727
|
console.log(ansis.red(`\u9519\u8BEF: ${error}`));
|
|
1701
1728
|
return;
|
|
1702
1729
|
}
|
|
1730
|
+
if (await needsMigration()) {
|
|
1731
|
+
spinner = ora("\u68C0\u6D4B\u5230\u65E7\u7248\u672C\u914D\u7F6E\uFF0C\u6B63\u5728\u8FC1\u79FB...").start();
|
|
1732
|
+
const migrationResult = await migrateToV1_4_0();
|
|
1733
|
+
if (migrationResult.migratedFiles.length > 0) {
|
|
1734
|
+
spinner.info(ansis.cyan("\u914D\u7F6E\u8FC1\u79FB\u5B8C\u6210:"));
|
|
1735
|
+
console.log();
|
|
1736
|
+
for (const file of migrationResult.migratedFiles) {
|
|
1737
|
+
console.log(` ${ansis.green("\u2713")} ${file}`);
|
|
1738
|
+
}
|
|
1739
|
+
if (migrationResult.skipped.length > 0) {
|
|
1740
|
+
console.log();
|
|
1741
|
+
console.log(ansis.gray(" \u5DF2\u8DF3\u8FC7:"));
|
|
1742
|
+
for (const file of migrationResult.skipped) {
|
|
1743
|
+
console.log(` ${ansis.gray("\u25CB")} ${file}`);
|
|
1744
|
+
}
|
|
1745
|
+
}
|
|
1746
|
+
console.log();
|
|
1747
|
+
}
|
|
1748
|
+
if (migrationResult.errors.length > 0) {
|
|
1749
|
+
spinner.warn(ansis.yellow("\u8FC1\u79FB\u5B8C\u6210\uFF0C\u4F46\u6709\u90E8\u5206\u9519\u8BEF:"));
|
|
1750
|
+
for (const error of migrationResult.errors) {
|
|
1751
|
+
console.log(` ${ansis.red("\u2717")} ${error}`);
|
|
1752
|
+
}
|
|
1753
|
+
console.log();
|
|
1754
|
+
}
|
|
1755
|
+
}
|
|
1703
1756
|
const config = await readCcgConfig();
|
|
1704
1757
|
spinner = ora("\u6B63\u5728\u66F4\u65B0\u5DE5\u4F5C\u6D41\u548C codeagent-wrapper \u4E8C\u8FDB\u5236...").start();
|
|
1705
1758
|
try {
|