ccman 3.3.21 → 3.3.23
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/index.js +43 -19
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -9,6 +9,33 @@ var __export = (target, all) => {
|
|
|
9
9
|
__defProp(target, name, { get: all[name], enumerable: true });
|
|
10
10
|
};
|
|
11
11
|
|
|
12
|
+
// ../core/dist/version.js
|
|
13
|
+
import { existsSync, readFileSync } from "fs";
|
|
14
|
+
import { dirname, join } from "path";
|
|
15
|
+
import { fileURLToPath } from "url";
|
|
16
|
+
function resolveVersionFromRuntimeDir(runtimeDir) {
|
|
17
|
+
const candidates = [join(runtimeDir, "../package.json"), join(runtimeDir, "../../package.json")];
|
|
18
|
+
for (const packageJsonPath of candidates) {
|
|
19
|
+
if (!existsSync(packageJsonPath)) {
|
|
20
|
+
continue;
|
|
21
|
+
}
|
|
22
|
+
const pkg = JSON.parse(readFileSync(packageJsonPath, "utf-8"));
|
|
23
|
+
if (typeof pkg.version === "string" && pkg.version.length > 0) {
|
|
24
|
+
return pkg.version;
|
|
25
|
+
}
|
|
26
|
+
}
|
|
27
|
+
throw new Error(`Unable to resolve package.json version from runtime dir: ${runtimeDir}`);
|
|
28
|
+
}
|
|
29
|
+
function loadVersion(moduleUrl = import.meta.url) {
|
|
30
|
+
const runtimeDir = dirname(fileURLToPath(moduleUrl));
|
|
31
|
+
return resolveVersionFromRuntimeDir(runtimeDir);
|
|
32
|
+
}
|
|
33
|
+
var init_version = __esm({
|
|
34
|
+
"../core/dist/version.js"() {
|
|
35
|
+
"use strict";
|
|
36
|
+
}
|
|
37
|
+
});
|
|
38
|
+
|
|
12
39
|
// ../types/dist/index.js
|
|
13
40
|
var TOOL_TYPES, MAIN_TOOL_TYPES, TOOL_CONFIG;
|
|
14
41
|
var init_dist = __esm({
|
|
@@ -242,7 +269,7 @@ var init_template = __esm({
|
|
|
242
269
|
// ../core/dist/writers/codex.js
|
|
243
270
|
import * as fs2 from "fs";
|
|
244
271
|
import * as path3 from "path";
|
|
245
|
-
import { fileURLToPath } from "url";
|
|
272
|
+
import { fileURLToPath as fileURLToPath2 } from "url";
|
|
246
273
|
import { parse as parseToml, stringify as stringifyToml } from "@iarna/toml";
|
|
247
274
|
function resolveTemplatePath(relativePath) {
|
|
248
275
|
const candidates = [
|
|
@@ -371,7 +398,7 @@ var init_codex = __esm({
|
|
|
371
398
|
init_paths();
|
|
372
399
|
init_file();
|
|
373
400
|
init_template();
|
|
374
|
-
__filename =
|
|
401
|
+
__filename = fileURLToPath2(import.meta.url);
|
|
375
402
|
__dirname = path3.dirname(__filename);
|
|
376
403
|
CODEX_DEFAULT_CONFIG = {
|
|
377
404
|
model: "gpt-5.4",
|
|
@@ -426,6 +453,8 @@ var init_codex = __esm({
|
|
|
426
453
|
"gmncodex.com",
|
|
427
454
|
"gmncode.cn",
|
|
428
455
|
"cdn.gmncode.cn",
|
|
456
|
+
"gmncode.com",
|
|
457
|
+
// Keep the historical typo for compatibility with previously written configs.
|
|
429
458
|
"gmn.codex.com",
|
|
430
459
|
"cdn.gmncode.com"
|
|
431
460
|
];
|
|
@@ -435,7 +464,7 @@ var init_codex = __esm({
|
|
|
435
464
|
// ../core/dist/writers/claude.js
|
|
436
465
|
import * as fs3 from "fs";
|
|
437
466
|
import * as path4 from "path";
|
|
438
|
-
import { fileURLToPath as
|
|
467
|
+
import { fileURLToPath as fileURLToPath3 } from "url";
|
|
439
468
|
function resolveTemplatePath2(relativePath) {
|
|
440
469
|
const candidates = [
|
|
441
470
|
// @ccman/core runtime (dist/writers -> templates)
|
|
@@ -492,7 +521,7 @@ var init_claude = __esm({
|
|
|
492
521
|
init_paths();
|
|
493
522
|
init_file();
|
|
494
523
|
init_template();
|
|
495
|
-
__filename2 =
|
|
524
|
+
__filename2 = fileURLToPath3(import.meta.url);
|
|
496
525
|
__dirname2 = path4.dirname(__filename2);
|
|
497
526
|
CLAUDE_CONFIG_TEMPLATE = {
|
|
498
527
|
env: {
|
|
@@ -832,7 +861,7 @@ var init_openclaw = __esm({
|
|
|
832
861
|
// ../core/dist/writers/gemini.js
|
|
833
862
|
import * as fs5 from "fs";
|
|
834
863
|
import * as path6 from "path";
|
|
835
|
-
import { fileURLToPath as
|
|
864
|
+
import { fileURLToPath as fileURLToPath4 } from "url";
|
|
836
865
|
function resolveTemplatePath3(relativePath) {
|
|
837
866
|
const candidates = [
|
|
838
867
|
// @ccman/core runtime (dist/writers -> templates)
|
|
@@ -992,7 +1021,7 @@ var init_gemini2 = __esm({
|
|
|
992
1021
|
init_paths();
|
|
993
1022
|
init_file();
|
|
994
1023
|
init_template();
|
|
995
|
-
__filename3 =
|
|
1024
|
+
__filename3 = fileURLToPath4(import.meta.url);
|
|
996
1025
|
__dirname3 = path6.dirname(__filename3);
|
|
997
1026
|
GEMINI_SETTINGS_TEMPLATE = {
|
|
998
1027
|
ide: {
|
|
@@ -1015,7 +1044,7 @@ var init_gemini2 = __esm({
|
|
|
1015
1044
|
// ../core/dist/writers/opencode.js
|
|
1016
1045
|
import * as fs6 from "fs";
|
|
1017
1046
|
import * as path7 from "path";
|
|
1018
|
-
import { fileURLToPath as
|
|
1047
|
+
import { fileURLToPath as fileURLToPath5 } from "url";
|
|
1019
1048
|
function resolveTemplatePath4(relativePath) {
|
|
1020
1049
|
const candidates = [
|
|
1021
1050
|
// @ccman/core runtime (dist/writers -> templates)
|
|
@@ -1149,7 +1178,7 @@ var init_opencode2 = __esm({
|
|
|
1149
1178
|
OPENCODE_MODEL = "openai/gpt-5.4";
|
|
1150
1179
|
OPENCODE_MODEL_KEY = "gpt-5.4";
|
|
1151
1180
|
OPENCODE_SECONDARY_MODEL_KEY = "gpt-5.3-codex";
|
|
1152
|
-
__filename4 =
|
|
1181
|
+
__filename4 = fileURLToPath5(import.meta.url);
|
|
1153
1182
|
__dirname4 = path7.dirname(__filename4);
|
|
1154
1183
|
DEFAULT_MODELS = {
|
|
1155
1184
|
[OPENCODE_MODEL_KEY]: {
|
|
@@ -1208,7 +1237,7 @@ var init_opencode2 = __esm({
|
|
|
1208
1237
|
// ../core/dist/writers/openclaw.js
|
|
1209
1238
|
import * as fs7 from "fs";
|
|
1210
1239
|
import * as path8 from "path";
|
|
1211
|
-
import { fileURLToPath as
|
|
1240
|
+
import { fileURLToPath as fileURLToPath6 } from "url";
|
|
1212
1241
|
function resolveTemplatePath5(relativePath) {
|
|
1213
1242
|
const candidates = [
|
|
1214
1243
|
// @ccman/core runtime (dist/writers -> templates)
|
|
@@ -1379,7 +1408,7 @@ var init_openclaw2 = __esm({
|
|
|
1379
1408
|
SECONDARY_MODEL_ID = "gpt-5.3-codex";
|
|
1380
1409
|
PRIMARY_MODEL_INPUTS = ["text", "image"];
|
|
1381
1410
|
SECONDARY_MODEL_INPUTS = ["text", "image"];
|
|
1382
|
-
__filename5 =
|
|
1411
|
+
__filename5 = fileURLToPath6(import.meta.url);
|
|
1383
1412
|
__dirname5 = path8.dirname(__filename5);
|
|
1384
1413
|
OPENCLAW_CONFIG_TEMPLATE = {
|
|
1385
1414
|
models: {
|
|
@@ -2870,13 +2899,11 @@ var init_claude_clean = __esm({
|
|
|
2870
2899
|
});
|
|
2871
2900
|
|
|
2872
2901
|
// ../core/dist/index.js
|
|
2873
|
-
|
|
2874
|
-
import { join as join5, dirname as dirname7 } from "path";
|
|
2875
|
-
import { fileURLToPath as fileURLToPath6 } from "url";
|
|
2876
|
-
var __filename6, __dirname6, pkg, VERSION;
|
|
2902
|
+
var VERSION;
|
|
2877
2903
|
var init_dist2 = __esm({
|
|
2878
2904
|
"../core/dist/index.js"() {
|
|
2879
2905
|
"use strict";
|
|
2906
|
+
init_version();
|
|
2880
2907
|
init_constants();
|
|
2881
2908
|
init_tool_manager();
|
|
2882
2909
|
init_codex2();
|
|
@@ -2895,10 +2922,7 @@ var init_dist2 = __esm({
|
|
|
2895
2922
|
init_merge_advanced();
|
|
2896
2923
|
init_export();
|
|
2897
2924
|
init_claude_clean();
|
|
2898
|
-
|
|
2899
|
-
__dirname6 = dirname7(__filename6);
|
|
2900
|
-
pkg = JSON.parse(readFileSync10(join5(__dirname6, "../../package.json"), "utf-8"));
|
|
2901
|
-
VERSION = pkg.version;
|
|
2925
|
+
VERSION = loadVersion();
|
|
2902
2926
|
}
|
|
2903
2927
|
});
|
|
2904
2928
|
|
|
@@ -7376,7 +7400,7 @@ var GMN1_PROFILE = {
|
|
|
7376
7400
|
},
|
|
7377
7401
|
{
|
|
7378
7402
|
label: "\u5168\u7403\u8FB9\u7F18 B",
|
|
7379
|
-
url: "https://
|
|
7403
|
+
url: "https://gmncode.com",
|
|
7380
7404
|
description: "\u5168\u7403\u8FB9\u7F18\u8282\u70B9\u52A0\u901F"
|
|
7381
7405
|
},
|
|
7382
7406
|
{
|