ccg-workflow 1.7.94 → 1.7.95
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/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 { z as diagnoseMcpConfig, A as isWindows, B as readClaudeCodeConfig, C as fixWindowsMcpConfig, D as writeClaudeCodeConfig, r as readCcgConfig, b as initI18n, a as i18n, s as showMainMenu, i as init, E as configMcp, F as version } from './shared/ccg-workflow.
|
|
4
|
+
import { z as diagnoseMcpConfig, A as isWindows, B as readClaudeCodeConfig, C as fixWindowsMcpConfig, D as writeClaudeCodeConfig, r as readCcgConfig, b as initI18n, a as i18n, s as showMainMenu, i as init, E as configMcp, F as version } from './shared/ccg-workflow.BBGfqJul.mjs';
|
|
5
5
|
import 'inquirer';
|
|
6
6
|
import 'node:child_process';
|
|
7
7
|
import 'node:util';
|
package/dist/index.mjs
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
export { c as changeLanguage, x as checkForUpdates, y as compareVersions, d as createDefaultConfig, e as createDefaultRouting, g as getCcgDir, f as getConfigPath, t as getCurrentVersion, v as getLatestVersion, j as getWorkflowById, h as getWorkflowConfigs, a as i18n, i as init, b as initI18n, l as installAceTool, m as installAceToolRs, k as installWorkflows, p as migrateToV1_4_0, q as needsMigration, r as readCcgConfig, s as showMainMenu, o as uninstallAceTool, n as uninstallWorkflows, u as update, w as writeCcgConfig } from './shared/ccg-workflow.
|
|
1
|
+
export { c as changeLanguage, x as checkForUpdates, y as compareVersions, d as createDefaultConfig, e as createDefaultRouting, g as getCcgDir, f as getConfigPath, t as getCurrentVersion, v as getLatestVersion, j as getWorkflowById, h as getWorkflowConfigs, a as i18n, i as init, b as initI18n, l as installAceTool, m as installAceToolRs, k as installWorkflows, p as migrateToV1_4_0, q as needsMigration, r as readCcgConfig, s as showMainMenu, o as uninstallAceTool, n as uninstallWorkflows, u as update, w as writeCcgConfig } from './shared/ccg-workflow.BBGfqJul.mjs';
|
|
2
2
|
import 'ansis';
|
|
3
3
|
import 'inquirer';
|
|
4
4
|
import 'node:child_process';
|
|
@@ -10,7 +10,7 @@ import { parse, stringify } from 'smol-toml';
|
|
|
10
10
|
import i18next from 'i18next';
|
|
11
11
|
import ora from 'ora';
|
|
12
12
|
|
|
13
|
-
const version = "1.7.
|
|
13
|
+
const version = "1.7.95";
|
|
14
14
|
|
|
15
15
|
function cmd(id, order, category, name, nameEn, description, descriptionEn, cmdOverride) {
|
|
16
16
|
return {
|
|
@@ -629,8 +629,8 @@ const EXPECTED_BINARY_VERSION = "5.8.0";
|
|
|
629
629
|
const GITHUB_REPO = "fengshao1227/ccg-workflow";
|
|
630
630
|
const RELEASE_TAG = "preset";
|
|
631
631
|
const BINARY_SOURCES = [
|
|
632
|
-
{ name: "
|
|
633
|
-
{ name: "
|
|
632
|
+
{ name: "Cloudflare R2", url: "https://pub-29270440a0854a49bf1589cd3662c067.r2.dev/preset", timeoutMs: 15e3 },
|
|
633
|
+
{ name: "GitHub Release", url: `https://github.com/${GITHUB_REPO}/releases/download/${RELEASE_TAG}`, timeoutMs: 6e4 }
|
|
634
634
|
];
|
|
635
635
|
async function downloadFromUrl(url, destPath, timeoutMs, maxAttempts = 2) {
|
|
636
636
|
for (let attempt = 1; attempt <= maxAttempts; attempt++) {
|
|
@@ -885,6 +885,19 @@ async function verifyBinary(installDir) {
|
|
|
885
885
|
return false;
|
|
886
886
|
}
|
|
887
887
|
}
|
|
888
|
+
async function verifyBinaryVersion(installDir) {
|
|
889
|
+
const binDir = join(installDir, "bin");
|
|
890
|
+
const wrapperName = process.platform === "win32" ? "codeagent-wrapper.exe" : "codeagent-wrapper";
|
|
891
|
+
const wrapperPath = join(binDir, wrapperName);
|
|
892
|
+
try {
|
|
893
|
+
const { execSync } = await import('node:child_process');
|
|
894
|
+
const output = execSync(`"${wrapperPath}" --version`, { stdio: "pipe" }).toString().trim();
|
|
895
|
+
const version = output.replace(/^.*version\s*/, "");
|
|
896
|
+
return version === EXPECTED_BINARY_VERSION;
|
|
897
|
+
} catch {
|
|
898
|
+
return false;
|
|
899
|
+
}
|
|
900
|
+
}
|
|
888
901
|
function showBinaryDownloadWarning(binDir) {
|
|
889
902
|
const binaryExt = process.platform === "win32" ? ".exe" : "";
|
|
890
903
|
const platformLabel = process.platform === "darwin" ? process.arch === "arm64" ? "darwin-arm64" : "darwin-amd64" : process.platform === "linux" ? process.arch === "arm64" ? "linux-arm64" : "linux-amd64" : process.arch === "arm64" ? "windows-arm64" : "windows-amd64";
|
|
@@ -1083,6 +1096,32 @@ async function uninstallWorkflows(installDir, options) {
|
|
|
1083
1096
|
return result;
|
|
1084
1097
|
}
|
|
1085
1098
|
|
|
1099
|
+
const installer = {
|
|
1100
|
+
__proto__: null,
|
|
1101
|
+
getAllCommandIds: getAllCommandIds,
|
|
1102
|
+
getWorkflowById: getWorkflowById,
|
|
1103
|
+
getWorkflowConfigs: getWorkflowConfigs,
|
|
1104
|
+
injectConfigVariables: injectConfigVariables,
|
|
1105
|
+
installAceTool: installAceTool,
|
|
1106
|
+
installAceToolRs: installAceToolRs,
|
|
1107
|
+
installContextWeaver: installContextWeaver,
|
|
1108
|
+
installFastContext: installFastContext,
|
|
1109
|
+
installMcpServer: installMcpServer,
|
|
1110
|
+
installWorkflows: installWorkflows,
|
|
1111
|
+
removeFastContextPrompt: removeFastContextPrompt,
|
|
1112
|
+
showBinaryDownloadWarning: showBinaryDownloadWarning,
|
|
1113
|
+
syncMcpToCodex: syncMcpToCodex,
|
|
1114
|
+
syncMcpToGemini: syncMcpToGemini,
|
|
1115
|
+
uninstallAceTool: uninstallAceTool,
|
|
1116
|
+
uninstallContextWeaver: uninstallContextWeaver,
|
|
1117
|
+
uninstallFastContext: uninstallFastContext,
|
|
1118
|
+
uninstallMcpServer: uninstallMcpServer,
|
|
1119
|
+
uninstallWorkflows: uninstallWorkflows,
|
|
1120
|
+
verifyBinary: verifyBinary,
|
|
1121
|
+
verifyBinaryVersion: verifyBinaryVersion,
|
|
1122
|
+
writeFastContextPrompt: writeFastContextPrompt
|
|
1123
|
+
};
|
|
1124
|
+
|
|
1086
1125
|
async function syncMcpMirrors() {
|
|
1087
1126
|
const [codex, gemini] = await Promise.all([syncMcpToCodex(), syncMcpToGemini()]);
|
|
1088
1127
|
const synced = [];
|
|
@@ -3494,6 +3533,12 @@ async function performUpdate(fromVersion, toVersion, isNewVersion) {
|
|
|
3494
3533
|
}
|
|
3495
3534
|
if (!await verifyBinary(installDir)) {
|
|
3496
3535
|
showBinaryDownloadWarning(join(installDir, "bin"));
|
|
3536
|
+
} else {
|
|
3537
|
+
const { verifyBinaryVersion } = await Promise.resolve().then(function () { return installer; });
|
|
3538
|
+
const versionOk = await verifyBinaryVersion(installDir);
|
|
3539
|
+
if (!versionOk) {
|
|
3540
|
+
showBinaryDownloadWarning(join(installDir, "bin"));
|
|
3541
|
+
}
|
|
3497
3542
|
}
|
|
3498
3543
|
} else {
|
|
3499
3544
|
console.log();
|
package/package.json
CHANGED