@kevisual/project-search 0.0.8 → 0.0.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/dist/app.d.ts +15 -30
- package/dist/app.js +397 -175
- package/dist/remote.js +398 -176
- package/package.json +1 -1
package/dist/remote.js
CHANGED
|
@@ -45,7 +45,7 @@ var __export = (target, all) => {
|
|
|
45
45
|
};
|
|
46
46
|
var __require = /* @__PURE__ */ createRequire(import.meta.url);
|
|
47
47
|
|
|
48
|
-
//
|
|
48
|
+
// node_modules/fast-glob/out/utils/array.js
|
|
49
49
|
var require_array = __commonJS((exports) => {
|
|
50
50
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
51
51
|
exports.splitWhen = exports.flatten = undefined;
|
|
@@ -69,7 +69,7 @@ var require_array = __commonJS((exports) => {
|
|
|
69
69
|
exports.splitWhen = splitWhen;
|
|
70
70
|
});
|
|
71
71
|
|
|
72
|
-
//
|
|
72
|
+
// node_modules/fast-glob/out/utils/errno.js
|
|
73
73
|
var require_errno = __commonJS((exports) => {
|
|
74
74
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
75
75
|
exports.isEnoentCodeError = undefined;
|
|
@@ -79,7 +79,7 @@ var require_errno = __commonJS((exports) => {
|
|
|
79
79
|
exports.isEnoentCodeError = isEnoentCodeError;
|
|
80
80
|
});
|
|
81
81
|
|
|
82
|
-
//
|
|
82
|
+
// node_modules/fast-glob/out/utils/fs.js
|
|
83
83
|
var require_fs = __commonJS((exports) => {
|
|
84
84
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
85
85
|
exports.createDirentFromStats = undefined;
|
|
@@ -102,7 +102,7 @@ var require_fs = __commonJS((exports) => {
|
|
|
102
102
|
exports.createDirentFromStats = createDirentFromStats;
|
|
103
103
|
});
|
|
104
104
|
|
|
105
|
-
//
|
|
105
|
+
// node_modules/fast-glob/out/utils/path.js
|
|
106
106
|
var require_path = __commonJS((exports) => {
|
|
107
107
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
108
108
|
exports.convertPosixPathToPattern = exports.convertWindowsPathToPattern = exports.convertPathToPattern = exports.escapePosixPath = exports.escapeWindowsPath = exports.escape = exports.removeLeadingDotSegment = exports.makeAbsolute = exports.unixify = undefined;
|
|
@@ -152,7 +152,7 @@ var require_path = __commonJS((exports) => {
|
|
|
152
152
|
exports.convertPosixPathToPattern = convertPosixPathToPattern;
|
|
153
153
|
});
|
|
154
154
|
|
|
155
|
-
//
|
|
155
|
+
// node_modules/is-extglob/index.js
|
|
156
156
|
var require_is_extglob = __commonJS((exports, module) => {
|
|
157
157
|
/*!
|
|
158
158
|
* is-extglob <https://github.com/jonschlinkert/is-extglob>
|
|
@@ -174,7 +174,7 @@ var require_is_extglob = __commonJS((exports, module) => {
|
|
|
174
174
|
};
|
|
175
175
|
});
|
|
176
176
|
|
|
177
|
-
//
|
|
177
|
+
// node_modules/is-glob/index.js
|
|
178
178
|
var require_is_glob = __commonJS((exports, module) => {
|
|
179
179
|
/*!
|
|
180
180
|
* is-glob <https://github.com/jonschlinkert/is-glob>
|
|
@@ -309,7 +309,7 @@ var require_is_glob = __commonJS((exports, module) => {
|
|
|
309
309
|
};
|
|
310
310
|
});
|
|
311
311
|
|
|
312
|
-
//
|
|
312
|
+
// node_modules/glob-parent/index.js
|
|
313
313
|
var require_glob_parent = __commonJS((exports, module) => {
|
|
314
314
|
var isGlob = require_is_glob();
|
|
315
315
|
var pathPosixDirname = __require("path").posix.dirname;
|
|
@@ -335,7 +335,7 @@ var require_glob_parent = __commonJS((exports, module) => {
|
|
|
335
335
|
};
|
|
336
336
|
});
|
|
337
337
|
|
|
338
|
-
//
|
|
338
|
+
// node_modules/braces/lib/utils.js
|
|
339
339
|
var require_utils = __commonJS((exports) => {
|
|
340
340
|
exports.isInteger = (num) => {
|
|
341
341
|
if (typeof num === "number") {
|
|
@@ -422,7 +422,7 @@ var require_utils = __commonJS((exports) => {
|
|
|
422
422
|
};
|
|
423
423
|
});
|
|
424
424
|
|
|
425
|
-
//
|
|
425
|
+
// node_modules/braces/lib/stringify.js
|
|
426
426
|
var require_stringify = __commonJS((exports, module) => {
|
|
427
427
|
var utils = require_utils();
|
|
428
428
|
module.exports = (ast, options = {}) => {
|
|
@@ -450,7 +450,7 @@ var require_stringify = __commonJS((exports, module) => {
|
|
|
450
450
|
};
|
|
451
451
|
});
|
|
452
452
|
|
|
453
|
-
//
|
|
453
|
+
// node_modules/is-number/index.js
|
|
454
454
|
var require_is_number = __commonJS((exports, module) => {
|
|
455
455
|
/*!
|
|
456
456
|
* is-number <https://github.com/jonschlinkert/is-number>
|
|
@@ -469,7 +469,7 @@ var require_is_number = __commonJS((exports, module) => {
|
|
|
469
469
|
};
|
|
470
470
|
});
|
|
471
471
|
|
|
472
|
-
//
|
|
472
|
+
// node_modules/to-regex-range/index.js
|
|
473
473
|
var require_to_regex_range = __commonJS((exports, module) => {
|
|
474
474
|
/*!
|
|
475
475
|
* to-regex-range <https://github.com/micromatch/to-regex-range>
|
|
@@ -684,7 +684,7 @@ var require_to_regex_range = __commonJS((exports, module) => {
|
|
|
684
684
|
module.exports = toRegexRange;
|
|
685
685
|
});
|
|
686
686
|
|
|
687
|
-
//
|
|
687
|
+
// node_modules/fill-range/index.js
|
|
688
688
|
var require_fill_range = __commonJS((exports, module) => {
|
|
689
689
|
/*!
|
|
690
690
|
* fill-range <https://github.com/jonschlinkert/fill-range>
|
|
@@ -893,7 +893,7 @@ var require_fill_range = __commonJS((exports, module) => {
|
|
|
893
893
|
module.exports = fill;
|
|
894
894
|
});
|
|
895
895
|
|
|
896
|
-
//
|
|
896
|
+
// node_modules/braces/lib/compile.js
|
|
897
897
|
var require_compile = __commonJS((exports, module) => {
|
|
898
898
|
var fill = require_fill_range();
|
|
899
899
|
var utils = require_utils();
|
|
@@ -942,7 +942,7 @@ var require_compile = __commonJS((exports, module) => {
|
|
|
942
942
|
module.exports = compile;
|
|
943
943
|
});
|
|
944
944
|
|
|
945
|
-
//
|
|
945
|
+
// node_modules/braces/lib/expand.js
|
|
946
946
|
var require_expand = __commonJS((exports, module) => {
|
|
947
947
|
var fill = require_fill_range();
|
|
948
948
|
var stringify = require_stringify();
|
|
@@ -1036,7 +1036,7 @@ var require_expand = __commonJS((exports, module) => {
|
|
|
1036
1036
|
module.exports = expand;
|
|
1037
1037
|
});
|
|
1038
1038
|
|
|
1039
|
-
//
|
|
1039
|
+
// node_modules/braces/lib/constants.js
|
|
1040
1040
|
var require_constants2 = __commonJS((exports, module) => {
|
|
1041
1041
|
module.exports = {
|
|
1042
1042
|
MAX_LENGTH: 1e4,
|
|
@@ -1088,7 +1088,7 @@ var require_constants2 = __commonJS((exports, module) => {
|
|
|
1088
1088
|
};
|
|
1089
1089
|
});
|
|
1090
1090
|
|
|
1091
|
-
//
|
|
1091
|
+
// node_modules/braces/lib/parse.js
|
|
1092
1092
|
var require_parse = __commonJS((exports, module) => {
|
|
1093
1093
|
var stringify = require_stringify();
|
|
1094
1094
|
var {
|
|
@@ -1315,7 +1315,7 @@ var require_parse = __commonJS((exports, module) => {
|
|
|
1315
1315
|
module.exports = parse2;
|
|
1316
1316
|
});
|
|
1317
1317
|
|
|
1318
|
-
//
|
|
1318
|
+
// node_modules/braces/index.js
|
|
1319
1319
|
var require_braces = __commonJS((exports, module) => {
|
|
1320
1320
|
var stringify = require_stringify();
|
|
1321
1321
|
var compile = require_compile();
|
|
@@ -1375,7 +1375,7 @@ var require_braces = __commonJS((exports, module) => {
|
|
|
1375
1375
|
module.exports = braces;
|
|
1376
1376
|
});
|
|
1377
1377
|
|
|
1378
|
-
//
|
|
1378
|
+
// node_modules/micromatch/node_modules/picomatch/lib/constants.js
|
|
1379
1379
|
var require_constants3 = __commonJS((exports, module) => {
|
|
1380
1380
|
var path2 = __require("path");
|
|
1381
1381
|
var WIN_SLASH = "\\\\/";
|
|
@@ -1515,7 +1515,7 @@ var require_constants3 = __commonJS((exports, module) => {
|
|
|
1515
1515
|
};
|
|
1516
1516
|
});
|
|
1517
1517
|
|
|
1518
|
-
//
|
|
1518
|
+
// node_modules/micromatch/node_modules/picomatch/lib/utils.js
|
|
1519
1519
|
var require_utils2 = __commonJS((exports) => {
|
|
1520
1520
|
var path2 = __require("path");
|
|
1521
1521
|
var win32 = process.platform === "win32";
|
|
@@ -1575,7 +1575,7 @@ var require_utils2 = __commonJS((exports) => {
|
|
|
1575
1575
|
};
|
|
1576
1576
|
});
|
|
1577
1577
|
|
|
1578
|
-
//
|
|
1578
|
+
// node_modules/micromatch/node_modules/picomatch/lib/scan.js
|
|
1579
1579
|
var require_scan = __commonJS((exports, module) => {
|
|
1580
1580
|
var utils = require_utils2();
|
|
1581
1581
|
var {
|
|
@@ -1890,7 +1890,7 @@ var require_scan = __commonJS((exports, module) => {
|
|
|
1890
1890
|
module.exports = scan;
|
|
1891
1891
|
});
|
|
1892
1892
|
|
|
1893
|
-
//
|
|
1893
|
+
// node_modules/micromatch/node_modules/picomatch/lib/parse.js
|
|
1894
1894
|
var require_parse2 = __commonJS((exports, module) => {
|
|
1895
1895
|
var constants = require_constants3();
|
|
1896
1896
|
var utils = require_utils2();
|
|
@@ -2668,7 +2668,7 @@ var require_parse2 = __commonJS((exports, module) => {
|
|
|
2668
2668
|
module.exports = parse2;
|
|
2669
2669
|
});
|
|
2670
2670
|
|
|
2671
|
-
//
|
|
2671
|
+
// node_modules/micromatch/node_modules/picomatch/lib/picomatch.js
|
|
2672
2672
|
var require_picomatch = __commonJS((exports, module) => {
|
|
2673
2673
|
var path2 = __require("path");
|
|
2674
2674
|
var scan = require_scan();
|
|
@@ -2809,7 +2809,7 @@ var require_picomatch = __commonJS((exports, module) => {
|
|
|
2809
2809
|
module.exports = picomatch;
|
|
2810
2810
|
});
|
|
2811
2811
|
|
|
2812
|
-
//
|
|
2812
|
+
// node_modules/micromatch/index.js
|
|
2813
2813
|
var require_micromatch = __commonJS((exports, module) => {
|
|
2814
2814
|
var util = __require("util");
|
|
2815
2815
|
var braces = require_braces();
|
|
@@ -2973,7 +2973,7 @@ var require_micromatch = __commonJS((exports, module) => {
|
|
|
2973
2973
|
module.exports = micromatch;
|
|
2974
2974
|
});
|
|
2975
2975
|
|
|
2976
|
-
//
|
|
2976
|
+
// node_modules/fast-glob/out/utils/pattern.js
|
|
2977
2977
|
var require_pattern = __commonJS((exports) => {
|
|
2978
2978
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
2979
2979
|
exports.isAbsolute = exports.partitionAbsoluteAndRelative = exports.removeDuplicateSlashes = exports.matchAny = exports.convertPatternsToRe = exports.makeRe = exports.getPatternParts = exports.expandBraceExpansion = exports.expandPatternsWithBraceExpansion = exports.isAffectDepthOfReadingPattern = exports.endsWithSlashGlobStar = exports.hasGlobStar = exports.getBaseDirectory = exports.isPatternRelatedToParentDirectory = exports.getPatternsOutsideCurrentDirectory = exports.getPatternsInsideCurrentDirectory = exports.getPositivePatterns = exports.getNegativePatterns = exports.isPositivePattern = exports.isNegativePattern = exports.convertToNegativePattern = exports.convertToPositivePattern = exports.isDynamicPattern = exports.isStaticPattern = undefined;
|
|
@@ -3135,7 +3135,7 @@ var require_pattern = __commonJS((exports) => {
|
|
|
3135
3135
|
exports.isAbsolute = isAbsolute;
|
|
3136
3136
|
});
|
|
3137
3137
|
|
|
3138
|
-
//
|
|
3138
|
+
// node_modules/merge2/index.js
|
|
3139
3139
|
var require_merge2 = __commonJS((exports, module) => {
|
|
3140
3140
|
var Stream = __require("stream");
|
|
3141
3141
|
var PassThrough = Stream.PassThrough;
|
|
@@ -3251,7 +3251,7 @@ var require_merge2 = __commonJS((exports, module) => {
|
|
|
3251
3251
|
}
|
|
3252
3252
|
});
|
|
3253
3253
|
|
|
3254
|
-
//
|
|
3254
|
+
// node_modules/fast-glob/out/utils/stream.js
|
|
3255
3255
|
var require_stream2 = __commonJS((exports) => {
|
|
3256
3256
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3257
3257
|
exports.merge = undefined;
|
|
@@ -3271,7 +3271,7 @@ var require_stream2 = __commonJS((exports) => {
|
|
|
3271
3271
|
}
|
|
3272
3272
|
});
|
|
3273
3273
|
|
|
3274
|
-
//
|
|
3274
|
+
// node_modules/fast-glob/out/utils/string.js
|
|
3275
3275
|
var require_string = __commonJS((exports) => {
|
|
3276
3276
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3277
3277
|
exports.isEmpty = exports.isString = undefined;
|
|
@@ -3285,7 +3285,7 @@ var require_string = __commonJS((exports) => {
|
|
|
3285
3285
|
exports.isEmpty = isEmpty;
|
|
3286
3286
|
});
|
|
3287
3287
|
|
|
3288
|
-
//
|
|
3288
|
+
// node_modules/fast-glob/out/utils/index.js
|
|
3289
3289
|
var require_utils3 = __commonJS((exports) => {
|
|
3290
3290
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3291
3291
|
exports.string = exports.stream = exports.pattern = exports.path = exports.fs = exports.errno = exports.array = undefined;
|
|
@@ -3305,7 +3305,7 @@ var require_utils3 = __commonJS((exports) => {
|
|
|
3305
3305
|
exports.string = string4;
|
|
3306
3306
|
});
|
|
3307
3307
|
|
|
3308
|
-
//
|
|
3308
|
+
// node_modules/fast-glob/out/managers/tasks.js
|
|
3309
3309
|
var require_tasks = __commonJS((exports) => {
|
|
3310
3310
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3311
3311
|
exports.convertPatternGroupToTask = exports.convertPatternGroupsToTasks = exports.groupPatternsByBaseDirectory = exports.getNegativePatternsAsPositive = exports.getPositivePatterns = exports.convertPatternsToTasks = exports.generate = undefined;
|
|
@@ -3388,7 +3388,7 @@ var require_tasks = __commonJS((exports) => {
|
|
|
3388
3388
|
exports.convertPatternGroupToTask = convertPatternGroupToTask;
|
|
3389
3389
|
});
|
|
3390
3390
|
|
|
3391
|
-
//
|
|
3391
|
+
// node_modules/@nodelib/fs.stat/out/providers/async.js
|
|
3392
3392
|
var require_async = __commonJS((exports) => {
|
|
3393
3393
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3394
3394
|
exports.read = undefined;
|
|
@@ -3427,7 +3427,7 @@ var require_async = __commonJS((exports) => {
|
|
|
3427
3427
|
}
|
|
3428
3428
|
});
|
|
3429
3429
|
|
|
3430
|
-
//
|
|
3430
|
+
// node_modules/@nodelib/fs.stat/out/providers/sync.js
|
|
3431
3431
|
var require_sync = __commonJS((exports) => {
|
|
3432
3432
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3433
3433
|
exports.read = undefined;
|
|
@@ -3452,7 +3452,7 @@ var require_sync = __commonJS((exports) => {
|
|
|
3452
3452
|
exports.read = read;
|
|
3453
3453
|
});
|
|
3454
3454
|
|
|
3455
|
-
//
|
|
3455
|
+
// node_modules/@nodelib/fs.stat/out/adapters/fs.js
|
|
3456
3456
|
var require_fs2 = __commonJS((exports) => {
|
|
3457
3457
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3458
3458
|
exports.createFileSystemAdapter = exports.FILE_SYSTEM_ADAPTER = undefined;
|
|
@@ -3472,7 +3472,7 @@ var require_fs2 = __commonJS((exports) => {
|
|
|
3472
3472
|
exports.createFileSystemAdapter = createFileSystemAdapter;
|
|
3473
3473
|
});
|
|
3474
3474
|
|
|
3475
|
-
//
|
|
3475
|
+
// node_modules/@nodelib/fs.stat/out/settings.js
|
|
3476
3476
|
var require_settings = __commonJS((exports) => {
|
|
3477
3477
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3478
3478
|
var fs = require_fs2();
|
|
@@ -3492,7 +3492,7 @@ var require_settings = __commonJS((exports) => {
|
|
|
3492
3492
|
exports.default = Settings;
|
|
3493
3493
|
});
|
|
3494
3494
|
|
|
3495
|
-
//
|
|
3495
|
+
// node_modules/@nodelib/fs.stat/out/index.js
|
|
3496
3496
|
var require_out = __commonJS((exports) => {
|
|
3497
3497
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3498
3498
|
exports.statSync = exports.stat = exports.Settings = undefined;
|
|
@@ -3521,7 +3521,7 @@ var require_out = __commonJS((exports) => {
|
|
|
3521
3521
|
}
|
|
3522
3522
|
});
|
|
3523
3523
|
|
|
3524
|
-
//
|
|
3524
|
+
// node_modules/queue-microtask/index.js
|
|
3525
3525
|
var require_queue_microtask = __commonJS((exports, module) => {
|
|
3526
3526
|
/*! queue-microtask. MIT License. Feross Aboukhadijeh <https://feross.org/opensource> */
|
|
3527
3527
|
var promise2;
|
|
@@ -3530,7 +3530,7 @@ var require_queue_microtask = __commonJS((exports, module) => {
|
|
|
3530
3530
|
}, 0));
|
|
3531
3531
|
});
|
|
3532
3532
|
|
|
3533
|
-
//
|
|
3533
|
+
// node_modules/run-parallel/index.js
|
|
3534
3534
|
var require_run_parallel = __commonJS((exports, module) => {
|
|
3535
3535
|
/*! run-parallel. MIT License. Feross Aboukhadijeh <https://feross.org/opensource> */
|
|
3536
3536
|
module.exports = runParallel;
|
|
@@ -3582,7 +3582,7 @@ var require_run_parallel = __commonJS((exports, module) => {
|
|
|
3582
3582
|
}
|
|
3583
3583
|
});
|
|
3584
3584
|
|
|
3585
|
-
//
|
|
3585
|
+
// node_modules/@nodelib/fs.scandir/out/constants.js
|
|
3586
3586
|
var require_constants4 = __commonJS((exports) => {
|
|
3587
3587
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3588
3588
|
exports.IS_SUPPORT_READDIR_WITH_FILE_TYPES = undefined;
|
|
@@ -3599,7 +3599,7 @@ var require_constants4 = __commonJS((exports) => {
|
|
|
3599
3599
|
exports.IS_SUPPORT_READDIR_WITH_FILE_TYPES = IS_MATCHED_BY_MAJOR || IS_MATCHED_BY_MAJOR_AND_MINOR;
|
|
3600
3600
|
});
|
|
3601
3601
|
|
|
3602
|
-
//
|
|
3602
|
+
// node_modules/@nodelib/fs.scandir/out/utils/fs.js
|
|
3603
3603
|
var require_fs3 = __commonJS((exports) => {
|
|
3604
3604
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3605
3605
|
exports.createDirentFromStats = undefined;
|
|
@@ -3622,7 +3622,7 @@ var require_fs3 = __commonJS((exports) => {
|
|
|
3622
3622
|
exports.createDirentFromStats = createDirentFromStats;
|
|
3623
3623
|
});
|
|
3624
3624
|
|
|
3625
|
-
//
|
|
3625
|
+
// node_modules/@nodelib/fs.scandir/out/utils/index.js
|
|
3626
3626
|
var require_utils4 = __commonJS((exports) => {
|
|
3627
3627
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3628
3628
|
exports.fs = undefined;
|
|
@@ -3630,7 +3630,7 @@ var require_utils4 = __commonJS((exports) => {
|
|
|
3630
3630
|
exports.fs = fs;
|
|
3631
3631
|
});
|
|
3632
3632
|
|
|
3633
|
-
//
|
|
3633
|
+
// node_modules/@nodelib/fs.scandir/out/providers/common.js
|
|
3634
3634
|
var require_common = __commonJS((exports) => {
|
|
3635
3635
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3636
3636
|
exports.joinPathSegments = undefined;
|
|
@@ -3643,7 +3643,7 @@ var require_common = __commonJS((exports) => {
|
|
|
3643
3643
|
exports.joinPathSegments = joinPathSegments;
|
|
3644
3644
|
});
|
|
3645
3645
|
|
|
3646
|
-
//
|
|
3646
|
+
// node_modules/@nodelib/fs.scandir/out/providers/async.js
|
|
3647
3647
|
var require_async2 = __commonJS((exports) => {
|
|
3648
3648
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3649
3649
|
exports.readdir = exports.readdirWithFileTypes = exports.read = undefined;
|
|
@@ -3750,7 +3750,7 @@ var require_async2 = __commonJS((exports) => {
|
|
|
3750
3750
|
}
|
|
3751
3751
|
});
|
|
3752
3752
|
|
|
3753
|
-
//
|
|
3753
|
+
// node_modules/@nodelib/fs.scandir/out/providers/sync.js
|
|
3754
3754
|
var require_sync2 = __commonJS((exports) => {
|
|
3755
3755
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3756
3756
|
exports.readdir = exports.readdirWithFileTypes = exports.read = undefined;
|
|
@@ -3806,7 +3806,7 @@ var require_sync2 = __commonJS((exports) => {
|
|
|
3806
3806
|
exports.readdir = readdir;
|
|
3807
3807
|
});
|
|
3808
3808
|
|
|
3809
|
-
//
|
|
3809
|
+
// node_modules/@nodelib/fs.scandir/out/adapters/fs.js
|
|
3810
3810
|
var require_fs4 = __commonJS((exports) => {
|
|
3811
3811
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3812
3812
|
exports.createFileSystemAdapter = exports.FILE_SYSTEM_ADAPTER = undefined;
|
|
@@ -3828,7 +3828,7 @@ var require_fs4 = __commonJS((exports) => {
|
|
|
3828
3828
|
exports.createFileSystemAdapter = createFileSystemAdapter;
|
|
3829
3829
|
});
|
|
3830
3830
|
|
|
3831
|
-
//
|
|
3831
|
+
// node_modules/@nodelib/fs.scandir/out/settings.js
|
|
3832
3832
|
var require_settings2 = __commonJS((exports) => {
|
|
3833
3833
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3834
3834
|
var path2 = __require("path");
|
|
@@ -3856,7 +3856,7 @@ var require_settings2 = __commonJS((exports) => {
|
|
|
3856
3856
|
exports.default = Settings;
|
|
3857
3857
|
});
|
|
3858
3858
|
|
|
3859
|
-
//
|
|
3859
|
+
// node_modules/@nodelib/fs.scandir/out/index.js
|
|
3860
3860
|
var require_out2 = __commonJS((exports) => {
|
|
3861
3861
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3862
3862
|
exports.Settings = exports.scandirSync = exports.scandir = undefined;
|
|
@@ -3885,7 +3885,7 @@ var require_out2 = __commonJS((exports) => {
|
|
|
3885
3885
|
}
|
|
3886
3886
|
});
|
|
3887
3887
|
|
|
3888
|
-
//
|
|
3888
|
+
// node_modules/reusify/reusify.js
|
|
3889
3889
|
var require_reusify = __commonJS((exports, module) => {
|
|
3890
3890
|
function reusify(Constructor) {
|
|
3891
3891
|
var head = new Constructor;
|
|
@@ -3913,7 +3913,7 @@ var require_reusify = __commonJS((exports, module) => {
|
|
|
3913
3913
|
module.exports = reusify;
|
|
3914
3914
|
});
|
|
3915
3915
|
|
|
3916
|
-
//
|
|
3916
|
+
// node_modules/fastq/queue.js
|
|
3917
3917
|
var require_queue = __commonJS((exports, module) => {
|
|
3918
3918
|
var reusify = require_reusify();
|
|
3919
3919
|
function fastqueue(context, worker, _concurrency) {
|
|
@@ -4196,7 +4196,7 @@ var require_queue = __commonJS((exports, module) => {
|
|
|
4196
4196
|
module.exports.promise = queueAsPromised;
|
|
4197
4197
|
});
|
|
4198
4198
|
|
|
4199
|
-
//
|
|
4199
|
+
// node_modules/@nodelib/fs.walk/out/readers/common.js
|
|
4200
4200
|
var require_common2 = __commonJS((exports) => {
|
|
4201
4201
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
4202
4202
|
exports.joinPathSegments = exports.replacePathSegmentSeparator = exports.isAppliedFilter = exports.isFatalError = undefined;
|
|
@@ -4227,7 +4227,7 @@ var require_common2 = __commonJS((exports) => {
|
|
|
4227
4227
|
exports.joinPathSegments = joinPathSegments;
|
|
4228
4228
|
});
|
|
4229
4229
|
|
|
4230
|
-
//
|
|
4230
|
+
// node_modules/@nodelib/fs.walk/out/readers/reader.js
|
|
4231
4231
|
var require_reader = __commonJS((exports) => {
|
|
4232
4232
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
4233
4233
|
var common = require_common2();
|
|
@@ -4242,7 +4242,7 @@ var require_reader = __commonJS((exports) => {
|
|
|
4242
4242
|
exports.default = Reader;
|
|
4243
4243
|
});
|
|
4244
4244
|
|
|
4245
|
-
//
|
|
4245
|
+
// node_modules/@nodelib/fs.walk/out/readers/async.js
|
|
4246
4246
|
var require_async3 = __commonJS((exports) => {
|
|
4247
4247
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
4248
4248
|
var events_1 = __require("events");
|
|
@@ -4343,7 +4343,7 @@ var require_async3 = __commonJS((exports) => {
|
|
|
4343
4343
|
exports.default = AsyncReader;
|
|
4344
4344
|
});
|
|
4345
4345
|
|
|
4346
|
-
//
|
|
4346
|
+
// node_modules/@nodelib/fs.walk/out/providers/async.js
|
|
4347
4347
|
var require_async4 = __commonJS((exports) => {
|
|
4348
4348
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
4349
4349
|
var async_1 = require_async3();
|
|
@@ -4377,7 +4377,7 @@ var require_async4 = __commonJS((exports) => {
|
|
|
4377
4377
|
}
|
|
4378
4378
|
});
|
|
4379
4379
|
|
|
4380
|
-
//
|
|
4380
|
+
// node_modules/@nodelib/fs.walk/out/providers/stream.js
|
|
4381
4381
|
var require_stream3 = __commonJS((exports) => {
|
|
4382
4382
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
4383
4383
|
var stream_1 = __require("stream");
|
|
@@ -4415,7 +4415,7 @@ var require_stream3 = __commonJS((exports) => {
|
|
|
4415
4415
|
exports.default = StreamProvider;
|
|
4416
4416
|
});
|
|
4417
4417
|
|
|
4418
|
-
//
|
|
4418
|
+
// node_modules/@nodelib/fs.walk/out/readers/sync.js
|
|
4419
4419
|
var require_sync3 = __commonJS((exports) => {
|
|
4420
4420
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
4421
4421
|
var fsScandir = require_out2();
|
|
@@ -4477,7 +4477,7 @@ var require_sync3 = __commonJS((exports) => {
|
|
|
4477
4477
|
exports.default = SyncReader;
|
|
4478
4478
|
});
|
|
4479
4479
|
|
|
4480
|
-
//
|
|
4480
|
+
// node_modules/@nodelib/fs.walk/out/providers/sync.js
|
|
4481
4481
|
var require_sync4 = __commonJS((exports) => {
|
|
4482
4482
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
4483
4483
|
var sync_1 = require_sync3();
|
|
@@ -4495,7 +4495,7 @@ var require_sync4 = __commonJS((exports) => {
|
|
|
4495
4495
|
exports.default = SyncProvider;
|
|
4496
4496
|
});
|
|
4497
4497
|
|
|
4498
|
-
//
|
|
4498
|
+
// node_modules/@nodelib/fs.walk/out/settings.js
|
|
4499
4499
|
var require_settings3 = __commonJS((exports) => {
|
|
4500
4500
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
4501
4501
|
var path2 = __require("path");
|
|
@@ -4525,7 +4525,7 @@ var require_settings3 = __commonJS((exports) => {
|
|
|
4525
4525
|
exports.default = Settings;
|
|
4526
4526
|
});
|
|
4527
4527
|
|
|
4528
|
-
//
|
|
4528
|
+
// node_modules/@nodelib/fs.walk/out/index.js
|
|
4529
4529
|
var require_out3 = __commonJS((exports) => {
|
|
4530
4530
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
4531
4531
|
exports.Settings = exports.walkStream = exports.walkSync = exports.walk = undefined;
|
|
@@ -4562,7 +4562,7 @@ var require_out3 = __commonJS((exports) => {
|
|
|
4562
4562
|
}
|
|
4563
4563
|
});
|
|
4564
4564
|
|
|
4565
|
-
//
|
|
4565
|
+
// node_modules/fast-glob/out/readers/reader.js
|
|
4566
4566
|
var require_reader2 = __commonJS((exports) => {
|
|
4567
4567
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
4568
4568
|
var path2 = __require("path");
|
|
@@ -4599,7 +4599,7 @@ var require_reader2 = __commonJS((exports) => {
|
|
|
4599
4599
|
exports.default = Reader;
|
|
4600
4600
|
});
|
|
4601
4601
|
|
|
4602
|
-
//
|
|
4602
|
+
// node_modules/fast-glob/out/readers/stream.js
|
|
4603
4603
|
var require_stream4 = __commonJS((exports) => {
|
|
4604
4604
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
4605
4605
|
var stream_1 = __require("stream");
|
|
@@ -4654,7 +4654,7 @@ var require_stream4 = __commonJS((exports) => {
|
|
|
4654
4654
|
exports.default = ReaderStream;
|
|
4655
4655
|
});
|
|
4656
4656
|
|
|
4657
|
-
//
|
|
4657
|
+
// node_modules/fast-glob/out/readers/async.js
|
|
4658
4658
|
var require_async5 = __commonJS((exports) => {
|
|
4659
4659
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
4660
4660
|
var fsWalk = require_out3();
|
|
@@ -4691,7 +4691,7 @@ var require_async5 = __commonJS((exports) => {
|
|
|
4691
4691
|
exports.default = ReaderAsync;
|
|
4692
4692
|
});
|
|
4693
4693
|
|
|
4694
|
-
//
|
|
4694
|
+
// node_modules/fast-glob/out/providers/matchers/matcher.js
|
|
4695
4695
|
var require_matcher = __commonJS((exports) => {
|
|
4696
4696
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
4697
4697
|
var utils = require_utils3();
|
|
@@ -4740,7 +4740,7 @@ var require_matcher = __commonJS((exports) => {
|
|
|
4740
4740
|
exports.default = Matcher;
|
|
4741
4741
|
});
|
|
4742
4742
|
|
|
4743
|
-
//
|
|
4743
|
+
// node_modules/fast-glob/out/providers/matchers/partial.js
|
|
4744
4744
|
var require_partial = __commonJS((exports) => {
|
|
4745
4745
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
4746
4746
|
var matcher_1 = require_matcher();
|
|
@@ -4775,7 +4775,7 @@ var require_partial = __commonJS((exports) => {
|
|
|
4775
4775
|
exports.default = PartialMatcher;
|
|
4776
4776
|
});
|
|
4777
4777
|
|
|
4778
|
-
//
|
|
4778
|
+
// node_modules/fast-glob/out/providers/filters/deep.js
|
|
4779
4779
|
var require_deep = __commonJS((exports) => {
|
|
4780
4780
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
4781
4781
|
var utils = require_utils3();
|
|
@@ -4838,7 +4838,7 @@ var require_deep = __commonJS((exports) => {
|
|
|
4838
4838
|
exports.default = DeepFilter;
|
|
4839
4839
|
});
|
|
4840
4840
|
|
|
4841
|
-
//
|
|
4841
|
+
// node_modules/fast-glob/out/providers/filters/entry.js
|
|
4842
4842
|
var require_entry = __commonJS((exports) => {
|
|
4843
4843
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
4844
4844
|
var utils = require_utils3();
|
|
@@ -4924,7 +4924,7 @@ var require_entry = __commonJS((exports) => {
|
|
|
4924
4924
|
exports.default = EntryFilter;
|
|
4925
4925
|
});
|
|
4926
4926
|
|
|
4927
|
-
//
|
|
4927
|
+
// node_modules/fast-glob/out/providers/filters/error.js
|
|
4928
4928
|
var require_error = __commonJS((exports) => {
|
|
4929
4929
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
4930
4930
|
var utils = require_utils3();
|
|
@@ -4943,7 +4943,7 @@ var require_error = __commonJS((exports) => {
|
|
|
4943
4943
|
exports.default = ErrorFilter;
|
|
4944
4944
|
});
|
|
4945
4945
|
|
|
4946
|
-
//
|
|
4946
|
+
// node_modules/fast-glob/out/providers/transformers/entry.js
|
|
4947
4947
|
var require_entry2 = __commonJS((exports) => {
|
|
4948
4948
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
4949
4949
|
var utils = require_utils3();
|
|
@@ -4973,7 +4973,7 @@ var require_entry2 = __commonJS((exports) => {
|
|
|
4973
4973
|
exports.default = EntryTransformer;
|
|
4974
4974
|
});
|
|
4975
4975
|
|
|
4976
|
-
//
|
|
4976
|
+
// node_modules/fast-glob/out/providers/provider.js
|
|
4977
4977
|
var require_provider = __commonJS((exports) => {
|
|
4978
4978
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
4979
4979
|
var path2 = __require("path");
|
|
@@ -5025,7 +5025,7 @@ var require_provider = __commonJS((exports) => {
|
|
|
5025
5025
|
exports.default = Provider;
|
|
5026
5026
|
});
|
|
5027
5027
|
|
|
5028
|
-
//
|
|
5028
|
+
// node_modules/fast-glob/out/providers/async.js
|
|
5029
5029
|
var require_async6 = __commonJS((exports) => {
|
|
5030
5030
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
5031
5031
|
var async_1 = require_async5();
|
|
@@ -5052,7 +5052,7 @@ var require_async6 = __commonJS((exports) => {
|
|
|
5052
5052
|
exports.default = ProviderAsync;
|
|
5053
5053
|
});
|
|
5054
5054
|
|
|
5055
|
-
//
|
|
5055
|
+
// node_modules/fast-glob/out/providers/stream.js
|
|
5056
5056
|
var require_stream5 = __commonJS((exports) => {
|
|
5057
5057
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
5058
5058
|
var stream_1 = __require("stream");
|
|
@@ -5083,7 +5083,7 @@ var require_stream5 = __commonJS((exports) => {
|
|
|
5083
5083
|
exports.default = ProviderStream;
|
|
5084
5084
|
});
|
|
5085
5085
|
|
|
5086
|
-
//
|
|
5086
|
+
// node_modules/fast-glob/out/readers/sync.js
|
|
5087
5087
|
var require_sync5 = __commonJS((exports) => {
|
|
5088
5088
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
5089
5089
|
var fsStat = require_out();
|
|
@@ -5129,7 +5129,7 @@ var require_sync5 = __commonJS((exports) => {
|
|
|
5129
5129
|
exports.default = ReaderSync;
|
|
5130
5130
|
});
|
|
5131
5131
|
|
|
5132
|
-
//
|
|
5132
|
+
// node_modules/fast-glob/out/providers/sync.js
|
|
5133
5133
|
var require_sync6 = __commonJS((exports) => {
|
|
5134
5134
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
5135
5135
|
var sync_1 = require_sync5();
|
|
@@ -5156,7 +5156,7 @@ var require_sync6 = __commonJS((exports) => {
|
|
|
5156
5156
|
exports.default = ProviderSync;
|
|
5157
5157
|
});
|
|
5158
5158
|
|
|
5159
|
-
//
|
|
5159
|
+
// node_modules/fast-glob/out/settings.js
|
|
5160
5160
|
var require_settings4 = __commonJS((exports) => {
|
|
5161
5161
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
5162
5162
|
exports.DEFAULT_FILE_SYSTEM_ADAPTER = undefined;
|
|
@@ -5214,7 +5214,7 @@ var require_settings4 = __commonJS((exports) => {
|
|
|
5214
5214
|
exports.default = Settings;
|
|
5215
5215
|
});
|
|
5216
5216
|
|
|
5217
|
-
//
|
|
5217
|
+
// node_modules/fast-glob/out/index.js
|
|
5218
5218
|
var require_out4 = __commonJS((exports, module) => {
|
|
5219
5219
|
var taskManager = require_tasks();
|
|
5220
5220
|
var async_1 = require_async6();
|
|
@@ -5312,7 +5312,7 @@ var require_out4 = __commonJS((exports, module) => {
|
|
|
5312
5312
|
module.exports = FastGlob;
|
|
5313
5313
|
});
|
|
5314
5314
|
|
|
5315
|
-
//
|
|
5315
|
+
// node_modules/eventemitter3/index.js
|
|
5316
5316
|
var require_eventemitter32 = __commonJS((exports, module) => {
|
|
5317
5317
|
var has = Object.prototype.hasOwnProperty;
|
|
5318
5318
|
var prefix = "~";
|
|
@@ -5490,7 +5490,7 @@ var require_eventemitter32 = __commonJS((exports, module) => {
|
|
|
5490
5490
|
}
|
|
5491
5491
|
});
|
|
5492
5492
|
|
|
5493
|
-
//
|
|
5493
|
+
// node_modules/@kevisual/router/dist/router.js
|
|
5494
5494
|
import { createRequire as createRequire2 } from "node:module";
|
|
5495
5495
|
import { webcrypto as crypto } from "node:crypto";
|
|
5496
5496
|
import http from "node:http";
|
|
@@ -23689,7 +23689,7 @@ class App extends QueryRouterServer {
|
|
|
23689
23689
|
}
|
|
23690
23690
|
}
|
|
23691
23691
|
|
|
23692
|
-
//
|
|
23692
|
+
// node_modules/meilisearch/dist/esm/index.js
|
|
23693
23693
|
var ErrorStatusCode = {
|
|
23694
23694
|
INDEX_CREATION_FAILED: "index_creation_failed",
|
|
23695
23695
|
MISSING_INDEX_UID: "missing_index_uid",
|
|
@@ -24947,6 +24947,21 @@ var TEXT_FILE_EXTENSIONS = [
|
|
|
24947
24947
|
".vue",
|
|
24948
24948
|
".svelte",
|
|
24949
24949
|
".astro",
|
|
24950
|
+
".html",
|
|
24951
|
+
".htm",
|
|
24952
|
+
".xhtml",
|
|
24953
|
+
".xml",
|
|
24954
|
+
".svg",
|
|
24955
|
+
".styl",
|
|
24956
|
+
".json",
|
|
24957
|
+
".yaml",
|
|
24958
|
+
".yml",
|
|
24959
|
+
".toml",
|
|
24960
|
+
".ini",
|
|
24961
|
+
".env",
|
|
24962
|
+
".properties",
|
|
24963
|
+
".conf",
|
|
24964
|
+
".config",
|
|
24950
24965
|
".npmrc",
|
|
24951
24966
|
".yarnrc",
|
|
24952
24967
|
".babelrc",
|
|
@@ -25016,7 +25031,18 @@ var TEXT_FILE_EXTENSIONS = [
|
|
|
25016
25031
|
".npmrc",
|
|
25017
25032
|
".yarnrc",
|
|
25018
25033
|
".babelrc",
|
|
25019
|
-
".webpackrc"
|
|
25034
|
+
".webpackrc",
|
|
25035
|
+
".lock",
|
|
25036
|
+
"-lock.json",
|
|
25037
|
+
"-lock.yaml",
|
|
25038
|
+
"-lock.yml",
|
|
25039
|
+
".lockb",
|
|
25040
|
+
".pem",
|
|
25041
|
+
".key",
|
|
25042
|
+
".crt",
|
|
25043
|
+
".cer",
|
|
25044
|
+
".p12",
|
|
25045
|
+
".pfx"
|
|
25020
25046
|
];
|
|
25021
25047
|
var CONFIG_FILE_NAMES = [
|
|
25022
25048
|
".gitignore",
|
|
@@ -25027,6 +25053,10 @@ var CONFIG_FILE_NAMES = [
|
|
|
25027
25053
|
".env.local",
|
|
25028
25054
|
".env.development",
|
|
25029
25055
|
".env.production",
|
|
25056
|
+
".env.test",
|
|
25057
|
+
".env.staging",
|
|
25058
|
+
".env.example",
|
|
25059
|
+
".env.sample",
|
|
25030
25060
|
"Dockerfile",
|
|
25031
25061
|
"Makefile",
|
|
25032
25062
|
"CMakeLists.txt",
|
|
@@ -25037,7 +25067,24 @@ var CONFIG_FILE_NAMES = [
|
|
|
25037
25067
|
".bashrc",
|
|
25038
25068
|
".zshrc",
|
|
25039
25069
|
".vimrc",
|
|
25040
|
-
".inputrc"
|
|
25070
|
+
".inputrc",
|
|
25071
|
+
"bun.lockb",
|
|
25072
|
+
"package-lock.json",
|
|
25073
|
+
"yarn.lock",
|
|
25074
|
+
"pnpm-lock.yaml",
|
|
25075
|
+
"pnpm-workspace.yaml",
|
|
25076
|
+
"Gemfile.lock",
|
|
25077
|
+
"Podfile.lock",
|
|
25078
|
+
"Cartfile.resolved",
|
|
25079
|
+
"composer.lock",
|
|
25080
|
+
"requirements.txt",
|
|
25081
|
+
"Pipfile.lock",
|
|
25082
|
+
"poetry.lock",
|
|
25083
|
+
"Cargo.lock",
|
|
25084
|
+
"go.sum",
|
|
25085
|
+
"go.mod",
|
|
25086
|
+
".vscode",
|
|
25087
|
+
".idea"
|
|
25041
25088
|
];
|
|
25042
25089
|
var isText = (filePath) => {
|
|
25043
25090
|
const fileName = path.basename(filePath);
|
|
@@ -25123,7 +25170,12 @@ function fileId(filePath) {
|
|
|
25123
25170
|
return Buffer.from(filePath).toString("base64url");
|
|
25124
25171
|
}
|
|
25125
25172
|
function fileHash(filePath) {
|
|
25126
|
-
|
|
25173
|
+
try {
|
|
25174
|
+
const content = fs.readFileSync(filePath);
|
|
25175
|
+
return crypto2.createHash("md5").update(content).digest("hex");
|
|
25176
|
+
} catch {
|
|
25177
|
+
return crypto2.createHash("md5").update(filePath).digest("hex");
|
|
25178
|
+
}
|
|
25127
25179
|
}
|
|
25128
25180
|
|
|
25129
25181
|
class ProjectSearch {
|
|
@@ -25369,11 +25421,11 @@ class ProjectStore {
|
|
|
25369
25421
|
name: input.name,
|
|
25370
25422
|
path: input.path,
|
|
25371
25423
|
repo: input.repo,
|
|
25372
|
-
title: existingDoc?.title,
|
|
25373
|
-
tags: existingDoc?.tags,
|
|
25374
|
-
summary: existingDoc?.summary,
|
|
25375
|
-
description: existingDoc?.description,
|
|
25376
|
-
link: existingDoc?.link,
|
|
25424
|
+
title: input.title ?? existingDoc?.title,
|
|
25425
|
+
tags: input.tags ?? existingDoc?.tags,
|
|
25426
|
+
summary: input.summary ?? existingDoc?.summary,
|
|
25427
|
+
description: input.description ?? existingDoc?.description,
|
|
25428
|
+
link: input.link ?? existingDoc?.link,
|
|
25377
25429
|
status: input.status ?? existingDoc?.status ?? "active"
|
|
25378
25430
|
};
|
|
25379
25431
|
await this.index.addDocuments([doc]);
|
|
@@ -25420,7 +25472,7 @@ class ProjectStore {
|
|
|
25420
25472
|
// src/project/project-listener/listener.ts
|
|
25421
25473
|
import { subscribe } from "@parcel/watcher";
|
|
25422
25474
|
import path3 from "node:path";
|
|
25423
|
-
import fs2 from "node:fs";
|
|
25475
|
+
import fs2, { existsSync } from "node:fs";
|
|
25424
25476
|
class ProjectListener {
|
|
25425
25477
|
projectPath;
|
|
25426
25478
|
subscribe = null;
|
|
@@ -25441,6 +25493,10 @@ class ProjectListener {
|
|
|
25441
25493
|
ignorePatterns = fs2.readFileSync(ignoreFile, "utf-8").split(`
|
|
25442
25494
|
`).map((line) => line.trim()).filter((line) => line && !line.startsWith("#"));
|
|
25443
25495
|
}
|
|
25496
|
+
if (!existsSync(projectPath)) {
|
|
25497
|
+
console.warn(`[ProjectListener] Project path does not exist: ${projectPath}`);
|
|
25498
|
+
throw new CustomError(`Project path does not exist: ${projectPath}`);
|
|
25499
|
+
}
|
|
25444
25500
|
const allIgnore = [...defaultIgnorePatterns, ...ignorePatterns];
|
|
25445
25501
|
const sub = await subscribe(this.projectPath, async (err, events) => {
|
|
25446
25502
|
if (err)
|
|
@@ -25495,7 +25551,7 @@ class ProjectListener {
|
|
|
25495
25551
|
}
|
|
25496
25552
|
}
|
|
25497
25553
|
|
|
25498
|
-
//
|
|
25554
|
+
// node_modules/eventemitter3/index.mjs
|
|
25499
25555
|
var import__2 = __toESM(require_eventemitter32(), 1);
|
|
25500
25556
|
|
|
25501
25557
|
// src/project/manager.ts
|
|
@@ -25530,15 +25586,17 @@ class ProjectManager {
|
|
|
25530
25586
|
console.log(`[ProjectManager] init: skip missing path ${doc.path}`);
|
|
25531
25587
|
continue;
|
|
25532
25588
|
}
|
|
25589
|
+
const shouldWatch = doc.status === "active";
|
|
25533
25590
|
try {
|
|
25534
|
-
await this.addProject({ name: doc.name, path: doc.path, repo: doc.repo });
|
|
25591
|
+
await this.addProject({ name: doc.name, path: doc.path, repo: doc.repo }, { startListening: shouldWatch });
|
|
25535
25592
|
} catch (err) {
|
|
25536
25593
|
console.error(`[ProjectManager] init: failed to add project ${doc.path}`, err);
|
|
25537
25594
|
}
|
|
25538
25595
|
}
|
|
25539
25596
|
console.log(`[ProjectManager] init done, loaded ${this.projects.size} project(s)`);
|
|
25540
25597
|
}
|
|
25541
|
-
async addProject(input) {
|
|
25598
|
+
async addProject(input, options = {}) {
|
|
25599
|
+
const { startListening = true } = options;
|
|
25542
25600
|
if (!fs3.existsSync(input.path)) {
|
|
25543
25601
|
throw new CustomError(`[ProjectManager] addProject: path does not exist: ${input.path}`);
|
|
25544
25602
|
}
|
|
@@ -25548,11 +25606,25 @@ class ProjectManager {
|
|
|
25548
25606
|
const listener = new ProjectListener({ projectPath: input.path, emitter: this.emitter });
|
|
25549
25607
|
const project = { ...input, listener };
|
|
25550
25608
|
this.projects.set(input.path, project);
|
|
25551
|
-
|
|
25609
|
+
const readmePath = path4.join(input.path, "README.md");
|
|
25610
|
+
let description = "";
|
|
25611
|
+
if (!input.description && fs3.existsSync(readmePath)) {
|
|
25612
|
+
const readmeContent = fs3.readFileSync(readmePath, "utf-8");
|
|
25613
|
+
description = readmeContent;
|
|
25614
|
+
}
|
|
25615
|
+
this.projectStore.ensureIndex().then(() => this.projectStore.addProject({
|
|
25616
|
+
name: input.name,
|
|
25617
|
+
path: input.path,
|
|
25618
|
+
repo: input.repo,
|
|
25619
|
+
status: startListening ? "active" : "inactive",
|
|
25620
|
+
description: input?.description || description
|
|
25621
|
+
})).catch((err) => {
|
|
25552
25622
|
console.error("[ProjectManager] projectStore.addProject failed:", err);
|
|
25553
25623
|
});
|
|
25554
|
-
|
|
25555
|
-
|
|
25624
|
+
if (startListening) {
|
|
25625
|
+
await listener.startListening();
|
|
25626
|
+
console.log(`[ProjectManager] watching: ${input.path}`);
|
|
25627
|
+
}
|
|
25556
25628
|
this.projectSearch.initialSync(input.path, input.repo).catch((err) => {
|
|
25557
25629
|
console.error("[ProjectManager] initialSync failed:", err);
|
|
25558
25630
|
});
|
|
@@ -25580,14 +25652,32 @@ class ProjectManager {
|
|
|
25580
25652
|
if (!project)
|
|
25581
25653
|
return;
|
|
25582
25654
|
await project.listener.stopListening();
|
|
25655
|
+
this.projectStore.updateProject(projectPath, { status: "inactive" }).catch((err) => {
|
|
25656
|
+
console.error("[ProjectManager] updateProject status failed:", err);
|
|
25657
|
+
});
|
|
25583
25658
|
console.log(`[ProjectManager] stopped: ${projectPath}`);
|
|
25584
25659
|
}
|
|
25660
|
+
async startProject(projectPath) {
|
|
25661
|
+
const project = this.projects.get(projectPath);
|
|
25662
|
+
if (!project)
|
|
25663
|
+
return;
|
|
25664
|
+
await project.listener.startListening();
|
|
25665
|
+
this.projectStore.updateProject(projectPath, { status: "active" }).catch((err) => {
|
|
25666
|
+
console.error("[ProjectManager] updateProject status failed:", err);
|
|
25667
|
+
});
|
|
25668
|
+
console.log(`[ProjectManager] started: ${projectPath}`);
|
|
25669
|
+
}
|
|
25585
25670
|
async getProjectInfo(project) {
|
|
25586
25671
|
const { listener, ...info } = project;
|
|
25587
25672
|
const storeDoc = await this.projectStore.getProject(info.path).catch(() => null);
|
|
25673
|
+
let status = storeDoc?.status === "active" ? "active" : "inactive";
|
|
25674
|
+
const exists = fileIsExist(info.path);
|
|
25675
|
+
if (!exists) {
|
|
25676
|
+
status = "unlive";
|
|
25677
|
+
}
|
|
25588
25678
|
return {
|
|
25589
25679
|
...info,
|
|
25590
|
-
status
|
|
25680
|
+
status,
|
|
25591
25681
|
id: storeDoc?.id,
|
|
25592
25682
|
title: storeDoc?.title,
|
|
25593
25683
|
tags: storeDoc?.tags,
|
|
@@ -25642,7 +25732,7 @@ var fileIsExist = (filePath) => {
|
|
|
25642
25732
|
}
|
|
25643
25733
|
};
|
|
25644
25734
|
|
|
25645
|
-
//
|
|
25735
|
+
// node_modules/@kevisual/context/dist/app.js
|
|
25646
25736
|
var isBrowser2 = typeof window !== "undefined" && typeof document !== "undefined";
|
|
25647
25737
|
var isBrowser22 = typeof window !== "undefined" && typeof window.document !== "undefined";
|
|
25648
25738
|
function getDefaultExportFromCjs(x) {
|
|
@@ -26248,7 +26338,7 @@ app.route({
|
|
|
26248
26338
|
description: "管理员权限验证中间件,在 auth 基础上进一步校验请求方是否具有管理员权限"
|
|
26249
26339
|
}).define(async (ctx) => {}).addTo(app, { overwrite: false });
|
|
26250
26340
|
|
|
26251
|
-
//
|
|
26341
|
+
// node_modules/zod/v4/classic/external.js
|
|
26252
26342
|
var exports_external2 = {};
|
|
26253
26343
|
__export(exports_external2, {
|
|
26254
26344
|
xor: () => xor2,
|
|
@@ -26489,7 +26579,7 @@ __export(exports_external2, {
|
|
|
26489
26579
|
$brand: () => $brand2
|
|
26490
26580
|
});
|
|
26491
26581
|
|
|
26492
|
-
//
|
|
26582
|
+
// node_modules/zod/v4/core/index.js
|
|
26493
26583
|
var exports_core3 = {};
|
|
26494
26584
|
__export(exports_core3, {
|
|
26495
26585
|
version: () => version3,
|
|
@@ -26767,7 +26857,7 @@ __export(exports_core3, {
|
|
|
26767
26857
|
$ZodAny: () => $ZodAny2
|
|
26768
26858
|
});
|
|
26769
26859
|
|
|
26770
|
-
//
|
|
26860
|
+
// node_modules/zod/v4/core/core.js
|
|
26771
26861
|
var NEVER2 = Object.freeze({
|
|
26772
26862
|
status: "aborted"
|
|
26773
26863
|
});
|
|
@@ -26843,7 +26933,7 @@ function config2(newConfig) {
|
|
|
26843
26933
|
Object.assign(globalConfig2, newConfig);
|
|
26844
26934
|
return globalConfig2;
|
|
26845
26935
|
}
|
|
26846
|
-
//
|
|
26936
|
+
// node_modules/zod/v4/core/util.js
|
|
26847
26937
|
var exports_util2 = {};
|
|
26848
26938
|
__export(exports_util2, {
|
|
26849
26939
|
unwrapMessage: () => unwrapMessage2,
|
|
@@ -27517,7 +27607,7 @@ class Class2 {
|
|
|
27517
27607
|
constructor(..._args) {}
|
|
27518
27608
|
}
|
|
27519
27609
|
|
|
27520
|
-
//
|
|
27610
|
+
// node_modules/zod/v4/core/errors.js
|
|
27521
27611
|
var initializer3 = (inst, def) => {
|
|
27522
27612
|
inst.name = "$ZodError";
|
|
27523
27613
|
Object.defineProperty(inst, "_zod", {
|
|
@@ -27654,7 +27744,7 @@ function prettifyError2(error48) {
|
|
|
27654
27744
|
`);
|
|
27655
27745
|
}
|
|
27656
27746
|
|
|
27657
|
-
//
|
|
27747
|
+
// node_modules/zod/v4/core/parse.js
|
|
27658
27748
|
var _parse2 = (_Err) => (schema, value, _ctx, _params) => {
|
|
27659
27749
|
const ctx = _ctx ? Object.assign(_ctx, { async: false }) : { async: false };
|
|
27660
27750
|
const result = schema._zod.run({ value, issues: [] }, ctx);
|
|
@@ -27741,7 +27831,7 @@ var _safeDecodeAsync2 = (_Err) => async (schema, value, _ctx) => {
|
|
|
27741
27831
|
return _safeParseAsync2(_Err)(schema, value, _ctx);
|
|
27742
27832
|
};
|
|
27743
27833
|
var safeDecodeAsync3 = /* @__PURE__ */ _safeDecodeAsync2($ZodRealError2);
|
|
27744
|
-
//
|
|
27834
|
+
// node_modules/zod/v4/core/regexes.js
|
|
27745
27835
|
var exports_regexes2 = {};
|
|
27746
27836
|
__export(exports_regexes2, {
|
|
27747
27837
|
xid: () => xid3,
|
|
@@ -27898,7 +27988,7 @@ var sha512_hex2 = /^[0-9a-fA-F]{128}$/;
|
|
|
27898
27988
|
var sha512_base642 = /* @__PURE__ */ fixedBase642(86, "==");
|
|
27899
27989
|
var sha512_base64url2 = /* @__PURE__ */ fixedBase64url2(86);
|
|
27900
27990
|
|
|
27901
|
-
//
|
|
27991
|
+
// node_modules/zod/v4/core/checks.js
|
|
27902
27992
|
var $ZodCheck2 = /* @__PURE__ */ $constructor2("$ZodCheck", (inst, def) => {
|
|
27903
27993
|
var _a2;
|
|
27904
27994
|
inst._zod ?? (inst._zod = {});
|
|
@@ -28445,7 +28535,7 @@ var $ZodCheckOverwrite2 = /* @__PURE__ */ $constructor2("$ZodCheckOverwrite", (i
|
|
|
28445
28535
|
};
|
|
28446
28536
|
});
|
|
28447
28537
|
|
|
28448
|
-
//
|
|
28538
|
+
// node_modules/zod/v4/core/doc.js
|
|
28449
28539
|
class Doc2 {
|
|
28450
28540
|
constructor(args = []) {
|
|
28451
28541
|
this.content = [];
|
|
@@ -28483,14 +28573,14 @@ class Doc2 {
|
|
|
28483
28573
|
}
|
|
28484
28574
|
}
|
|
28485
28575
|
|
|
28486
|
-
//
|
|
28576
|
+
// node_modules/zod/v4/core/versions.js
|
|
28487
28577
|
var version3 = {
|
|
28488
28578
|
major: 4,
|
|
28489
28579
|
minor: 3,
|
|
28490
28580
|
patch: 6
|
|
28491
28581
|
};
|
|
28492
28582
|
|
|
28493
|
-
//
|
|
28583
|
+
// node_modules/zod/v4/core/schemas.js
|
|
28494
28584
|
var $ZodType2 = /* @__PURE__ */ $constructor2("$ZodType", (inst, def) => {
|
|
28495
28585
|
var _a2;
|
|
28496
28586
|
inst ?? (inst = {});
|
|
@@ -30452,7 +30542,7 @@ function handleRefineResult2(result, payload, input, inst) {
|
|
|
30452
30542
|
payload.issues.push(issue2(_iss));
|
|
30453
30543
|
}
|
|
30454
30544
|
}
|
|
30455
|
-
//
|
|
30545
|
+
// node_modules/zod/v4/locales/index.js
|
|
30456
30546
|
var exports_locales2 = {};
|
|
30457
30547
|
__export(exports_locales2, {
|
|
30458
30548
|
zhTW: () => zh_TW_default2,
|
|
@@ -30506,7 +30596,7 @@ __export(exports_locales2, {
|
|
|
30506
30596
|
ar: () => ar_default2
|
|
30507
30597
|
});
|
|
30508
30598
|
|
|
30509
|
-
//
|
|
30599
|
+
// node_modules/zod/v4/locales/ar.js
|
|
30510
30600
|
var error48 = () => {
|
|
30511
30601
|
const Sizable = {
|
|
30512
30602
|
string: { unit: "حرف", verb: "أن يحوي" },
|
|
@@ -30612,7 +30702,7 @@ function ar_default2() {
|
|
|
30612
30702
|
localeError: error48()
|
|
30613
30703
|
};
|
|
30614
30704
|
}
|
|
30615
|
-
//
|
|
30705
|
+
// node_modules/zod/v4/locales/az.js
|
|
30616
30706
|
var error50 = () => {
|
|
30617
30707
|
const Sizable = {
|
|
30618
30708
|
string: { unit: "simvol", verb: "olmalıdır" },
|
|
@@ -30717,7 +30807,7 @@ function az_default2() {
|
|
|
30717
30807
|
localeError: error50()
|
|
30718
30808
|
};
|
|
30719
30809
|
}
|
|
30720
|
-
//
|
|
30810
|
+
// node_modules/zod/v4/locales/be.js
|
|
30721
30811
|
function getBelarusianPlural2(count, one, few, many) {
|
|
30722
30812
|
const absCount = Math.abs(count);
|
|
30723
30813
|
const lastDigit = absCount % 10;
|
|
@@ -30873,7 +30963,7 @@ function be_default2() {
|
|
|
30873
30963
|
localeError: error51()
|
|
30874
30964
|
};
|
|
30875
30965
|
}
|
|
30876
|
-
//
|
|
30966
|
+
// node_modules/zod/v4/locales/bg.js
|
|
30877
30967
|
var error52 = () => {
|
|
30878
30968
|
const Sizable = {
|
|
30879
30969
|
string: { unit: "символа", verb: "да съдържа" },
|
|
@@ -30993,7 +31083,7 @@ function bg_default2() {
|
|
|
30993
31083
|
localeError: error52()
|
|
30994
31084
|
};
|
|
30995
31085
|
}
|
|
30996
|
-
//
|
|
31086
|
+
// node_modules/zod/v4/locales/ca.js
|
|
30997
31087
|
var error53 = () => {
|
|
30998
31088
|
const Sizable = {
|
|
30999
31089
|
string: { unit: "caràcters", verb: "contenir" },
|
|
@@ -31100,7 +31190,7 @@ function ca_default2() {
|
|
|
31100
31190
|
localeError: error53()
|
|
31101
31191
|
};
|
|
31102
31192
|
}
|
|
31103
|
-
//
|
|
31193
|
+
// node_modules/zod/v4/locales/cs.js
|
|
31104
31194
|
var error54 = () => {
|
|
31105
31195
|
const Sizable = {
|
|
31106
31196
|
string: { unit: "znaků", verb: "mít" },
|
|
@@ -31211,7 +31301,7 @@ function cs_default2() {
|
|
|
31211
31301
|
localeError: error54()
|
|
31212
31302
|
};
|
|
31213
31303
|
}
|
|
31214
|
-
//
|
|
31304
|
+
// node_modules/zod/v4/locales/da.js
|
|
31215
31305
|
var error55 = () => {
|
|
31216
31306
|
const Sizable = {
|
|
31217
31307
|
string: { unit: "tegn", verb: "havde" },
|
|
@@ -31326,7 +31416,7 @@ function da_default2() {
|
|
|
31326
31416
|
localeError: error55()
|
|
31327
31417
|
};
|
|
31328
31418
|
}
|
|
31329
|
-
//
|
|
31419
|
+
// node_modules/zod/v4/locales/de.js
|
|
31330
31420
|
var error56 = () => {
|
|
31331
31421
|
const Sizable = {
|
|
31332
31422
|
string: { unit: "Zeichen", verb: "zu haben" },
|
|
@@ -31434,7 +31524,7 @@ function de_default2() {
|
|
|
31434
31524
|
localeError: error56()
|
|
31435
31525
|
};
|
|
31436
31526
|
}
|
|
31437
|
-
//
|
|
31527
|
+
// node_modules/zod/v4/locales/en.js
|
|
31438
31528
|
var error57 = () => {
|
|
31439
31529
|
const Sizable = {
|
|
31440
31530
|
string: { unit: "characters", verb: "to have" },
|
|
@@ -31540,7 +31630,7 @@ function en_default2() {
|
|
|
31540
31630
|
localeError: error57()
|
|
31541
31631
|
};
|
|
31542
31632
|
}
|
|
31543
|
-
//
|
|
31633
|
+
// node_modules/zod/v4/locales/eo.js
|
|
31544
31634
|
var error58 = () => {
|
|
31545
31635
|
const Sizable = {
|
|
31546
31636
|
string: { unit: "karaktrojn", verb: "havi" },
|
|
@@ -31649,7 +31739,7 @@ function eo_default2() {
|
|
|
31649
31739
|
localeError: error58()
|
|
31650
31740
|
};
|
|
31651
31741
|
}
|
|
31652
|
-
//
|
|
31742
|
+
// node_modules/zod/v4/locales/es.js
|
|
31653
31743
|
var error59 = () => {
|
|
31654
31744
|
const Sizable = {
|
|
31655
31745
|
string: { unit: "caracteres", verb: "tener" },
|
|
@@ -31781,7 +31871,7 @@ function es_default2() {
|
|
|
31781
31871
|
localeError: error59()
|
|
31782
31872
|
};
|
|
31783
31873
|
}
|
|
31784
|
-
//
|
|
31874
|
+
// node_modules/zod/v4/locales/fa.js
|
|
31785
31875
|
var error60 = () => {
|
|
31786
31876
|
const Sizable = {
|
|
31787
31877
|
string: { unit: "کاراکتر", verb: "داشته باشد" },
|
|
@@ -31895,7 +31985,7 @@ function fa_default2() {
|
|
|
31895
31985
|
localeError: error60()
|
|
31896
31986
|
};
|
|
31897
31987
|
}
|
|
31898
|
-
//
|
|
31988
|
+
// node_modules/zod/v4/locales/fi.js
|
|
31899
31989
|
var error61 = () => {
|
|
31900
31990
|
const Sizable = {
|
|
31901
31991
|
string: { unit: "merkkiä", subject: "merkkijonon" },
|
|
@@ -32007,7 +32097,7 @@ function fi_default2() {
|
|
|
32007
32097
|
localeError: error61()
|
|
32008
32098
|
};
|
|
32009
32099
|
}
|
|
32010
|
-
//
|
|
32100
|
+
// node_modules/zod/v4/locales/fr.js
|
|
32011
32101
|
var error62 = () => {
|
|
32012
32102
|
const Sizable = {
|
|
32013
32103
|
string: { unit: "caractères", verb: "avoir" },
|
|
@@ -32115,7 +32205,7 @@ function fr_default2() {
|
|
|
32115
32205
|
localeError: error62()
|
|
32116
32206
|
};
|
|
32117
32207
|
}
|
|
32118
|
-
//
|
|
32208
|
+
// node_modules/zod/v4/locales/fr-CA.js
|
|
32119
32209
|
var error63 = () => {
|
|
32120
32210
|
const Sizable = {
|
|
32121
32211
|
string: { unit: "caractères", verb: "avoir" },
|
|
@@ -32222,7 +32312,7 @@ function fr_CA_default2() {
|
|
|
32222
32312
|
localeError: error63()
|
|
32223
32313
|
};
|
|
32224
32314
|
}
|
|
32225
|
-
//
|
|
32315
|
+
// node_modules/zod/v4/locales/he.js
|
|
32226
32316
|
var error64 = () => {
|
|
32227
32317
|
const TypeNames = {
|
|
32228
32318
|
string: { label: "מחרוזת", gender: "f" },
|
|
@@ -32415,7 +32505,7 @@ function he_default2() {
|
|
|
32415
32505
|
localeError: error64()
|
|
32416
32506
|
};
|
|
32417
32507
|
}
|
|
32418
|
-
//
|
|
32508
|
+
// node_modules/zod/v4/locales/hu.js
|
|
32419
32509
|
var error65 = () => {
|
|
32420
32510
|
const Sizable = {
|
|
32421
32511
|
string: { unit: "karakter", verb: "legyen" },
|
|
@@ -32523,7 +32613,7 @@ function hu_default2() {
|
|
|
32523
32613
|
localeError: error65()
|
|
32524
32614
|
};
|
|
32525
32615
|
}
|
|
32526
|
-
//
|
|
32616
|
+
// node_modules/zod/v4/locales/hy.js
|
|
32527
32617
|
function getArmenianPlural2(count, one, many) {
|
|
32528
32618
|
return Math.abs(count) === 1 ? one : many;
|
|
32529
32619
|
}
|
|
@@ -32670,7 +32760,7 @@ function hy_default2() {
|
|
|
32670
32760
|
localeError: error66()
|
|
32671
32761
|
};
|
|
32672
32762
|
}
|
|
32673
|
-
//
|
|
32763
|
+
// node_modules/zod/v4/locales/id.js
|
|
32674
32764
|
var error67 = () => {
|
|
32675
32765
|
const Sizable = {
|
|
32676
32766
|
string: { unit: "karakter", verb: "memiliki" },
|
|
@@ -32776,7 +32866,7 @@ function id_default2() {
|
|
|
32776
32866
|
localeError: error67()
|
|
32777
32867
|
};
|
|
32778
32868
|
}
|
|
32779
|
-
//
|
|
32869
|
+
// node_modules/zod/v4/locales/is.js
|
|
32780
32870
|
var error68 = () => {
|
|
32781
32871
|
const Sizable = {
|
|
32782
32872
|
string: { unit: "stafi", verb: "að hafa" },
|
|
@@ -32885,7 +32975,7 @@ function is_default2() {
|
|
|
32885
32975
|
localeError: error68()
|
|
32886
32976
|
};
|
|
32887
32977
|
}
|
|
32888
|
-
//
|
|
32978
|
+
// node_modules/zod/v4/locales/it.js
|
|
32889
32979
|
var error69 = () => {
|
|
32890
32980
|
const Sizable = {
|
|
32891
32981
|
string: { unit: "caratteri", verb: "avere" },
|
|
@@ -32993,7 +33083,7 @@ function it_default2() {
|
|
|
32993
33083
|
localeError: error69()
|
|
32994
33084
|
};
|
|
32995
33085
|
}
|
|
32996
|
-
//
|
|
33086
|
+
// node_modules/zod/v4/locales/ja.js
|
|
32997
33087
|
var error70 = () => {
|
|
32998
33088
|
const Sizable = {
|
|
32999
33089
|
string: { unit: "文字", verb: "である" },
|
|
@@ -33100,7 +33190,7 @@ function ja_default2() {
|
|
|
33100
33190
|
localeError: error70()
|
|
33101
33191
|
};
|
|
33102
33192
|
}
|
|
33103
|
-
//
|
|
33193
|
+
// node_modules/zod/v4/locales/ka.js
|
|
33104
33194
|
var error71 = () => {
|
|
33105
33195
|
const Sizable = {
|
|
33106
33196
|
string: { unit: "სიმბოლო", verb: "უნდა შეიცავდეს" },
|
|
@@ -33212,7 +33302,7 @@ function ka_default2() {
|
|
|
33212
33302
|
localeError: error71()
|
|
33213
33303
|
};
|
|
33214
33304
|
}
|
|
33215
|
-
//
|
|
33305
|
+
// node_modules/zod/v4/locales/km.js
|
|
33216
33306
|
var error72 = () => {
|
|
33217
33307
|
const Sizable = {
|
|
33218
33308
|
string: { unit: "តួអក្សរ", verb: "គួរមាន" },
|
|
@@ -33323,11 +33413,11 @@ function km_default2() {
|
|
|
33323
33413
|
};
|
|
33324
33414
|
}
|
|
33325
33415
|
|
|
33326
|
-
//
|
|
33416
|
+
// node_modules/zod/v4/locales/kh.js
|
|
33327
33417
|
function kh_default2() {
|
|
33328
33418
|
return km_default2();
|
|
33329
33419
|
}
|
|
33330
|
-
//
|
|
33420
|
+
// node_modules/zod/v4/locales/ko.js
|
|
33331
33421
|
var error73 = () => {
|
|
33332
33422
|
const Sizable = {
|
|
33333
33423
|
string: { unit: "문자", verb: "to have" },
|
|
@@ -33438,7 +33528,7 @@ function ko_default2() {
|
|
|
33438
33528
|
localeError: error73()
|
|
33439
33529
|
};
|
|
33440
33530
|
}
|
|
33441
|
-
//
|
|
33531
|
+
// node_modules/zod/v4/locales/lt.js
|
|
33442
33532
|
var capitalizeFirstCharacter2 = (text) => {
|
|
33443
33533
|
return text.charAt(0).toUpperCase() + text.slice(1);
|
|
33444
33534
|
};
|
|
@@ -33641,7 +33731,7 @@ function lt_default2() {
|
|
|
33641
33731
|
localeError: error74()
|
|
33642
33732
|
};
|
|
33643
33733
|
}
|
|
33644
|
-
//
|
|
33734
|
+
// node_modules/zod/v4/locales/mk.js
|
|
33645
33735
|
var error75 = () => {
|
|
33646
33736
|
const Sizable = {
|
|
33647
33737
|
string: { unit: "знаци", verb: "да имаат" },
|
|
@@ -33750,7 +33840,7 @@ function mk_default2() {
|
|
|
33750
33840
|
localeError: error75()
|
|
33751
33841
|
};
|
|
33752
33842
|
}
|
|
33753
|
-
//
|
|
33843
|
+
// node_modules/zod/v4/locales/ms.js
|
|
33754
33844
|
var error76 = () => {
|
|
33755
33845
|
const Sizable = {
|
|
33756
33846
|
string: { unit: "aksara", verb: "mempunyai" },
|
|
@@ -33857,7 +33947,7 @@ function ms_default2() {
|
|
|
33857
33947
|
localeError: error76()
|
|
33858
33948
|
};
|
|
33859
33949
|
}
|
|
33860
|
-
//
|
|
33950
|
+
// node_modules/zod/v4/locales/nl.js
|
|
33861
33951
|
var error77 = () => {
|
|
33862
33952
|
const Sizable = {
|
|
33863
33953
|
string: { unit: "tekens", verb: "heeft" },
|
|
@@ -33967,7 +34057,7 @@ function nl_default2() {
|
|
|
33967
34057
|
localeError: error77()
|
|
33968
34058
|
};
|
|
33969
34059
|
}
|
|
33970
|
-
//
|
|
34060
|
+
// node_modules/zod/v4/locales/no.js
|
|
33971
34061
|
var error78 = () => {
|
|
33972
34062
|
const Sizable = {
|
|
33973
34063
|
string: { unit: "tegn", verb: "å ha" },
|
|
@@ -34075,7 +34165,7 @@ function no_default2() {
|
|
|
34075
34165
|
localeError: error78()
|
|
34076
34166
|
};
|
|
34077
34167
|
}
|
|
34078
|
-
//
|
|
34168
|
+
// node_modules/zod/v4/locales/ota.js
|
|
34079
34169
|
var error79 = () => {
|
|
34080
34170
|
const Sizable = {
|
|
34081
34171
|
string: { unit: "harf", verb: "olmalıdır" },
|
|
@@ -34184,7 +34274,7 @@ function ota_default2() {
|
|
|
34184
34274
|
localeError: error79()
|
|
34185
34275
|
};
|
|
34186
34276
|
}
|
|
34187
|
-
//
|
|
34277
|
+
// node_modules/zod/v4/locales/ps.js
|
|
34188
34278
|
var error80 = () => {
|
|
34189
34279
|
const Sizable = {
|
|
34190
34280
|
string: { unit: "توکي", verb: "ولري" },
|
|
@@ -34298,7 +34388,7 @@ function ps_default2() {
|
|
|
34298
34388
|
localeError: error80()
|
|
34299
34389
|
};
|
|
34300
34390
|
}
|
|
34301
|
-
//
|
|
34391
|
+
// node_modules/zod/v4/locales/pl.js
|
|
34302
34392
|
var error81 = () => {
|
|
34303
34393
|
const Sizable = {
|
|
34304
34394
|
string: { unit: "znaków", verb: "mieć" },
|
|
@@ -34407,7 +34497,7 @@ function pl_default2() {
|
|
|
34407
34497
|
localeError: error81()
|
|
34408
34498
|
};
|
|
34409
34499
|
}
|
|
34410
|
-
//
|
|
34500
|
+
// node_modules/zod/v4/locales/pt.js
|
|
34411
34501
|
var error82 = () => {
|
|
34412
34502
|
const Sizable = {
|
|
34413
34503
|
string: { unit: "caracteres", verb: "ter" },
|
|
@@ -34515,7 +34605,7 @@ function pt_default2() {
|
|
|
34515
34605
|
localeError: error82()
|
|
34516
34606
|
};
|
|
34517
34607
|
}
|
|
34518
|
-
//
|
|
34608
|
+
// node_modules/zod/v4/locales/ru.js
|
|
34519
34609
|
function getRussianPlural2(count, one, few, many) {
|
|
34520
34610
|
const absCount = Math.abs(count);
|
|
34521
34611
|
const lastDigit = absCount % 10;
|
|
@@ -34671,7 +34761,7 @@ function ru_default2() {
|
|
|
34671
34761
|
localeError: error83()
|
|
34672
34762
|
};
|
|
34673
34763
|
}
|
|
34674
|
-
//
|
|
34764
|
+
// node_modules/zod/v4/locales/sl.js
|
|
34675
34765
|
var error84 = () => {
|
|
34676
34766
|
const Sizable = {
|
|
34677
34767
|
string: { unit: "znakov", verb: "imeti" },
|
|
@@ -34780,7 +34870,7 @@ function sl_default2() {
|
|
|
34780
34870
|
localeError: error84()
|
|
34781
34871
|
};
|
|
34782
34872
|
}
|
|
34783
|
-
//
|
|
34873
|
+
// node_modules/zod/v4/locales/sv.js
|
|
34784
34874
|
var error85 = () => {
|
|
34785
34875
|
const Sizable = {
|
|
34786
34876
|
string: { unit: "tecken", verb: "att ha" },
|
|
@@ -34890,7 +34980,7 @@ function sv_default2() {
|
|
|
34890
34980
|
localeError: error85()
|
|
34891
34981
|
};
|
|
34892
34982
|
}
|
|
34893
|
-
//
|
|
34983
|
+
// node_modules/zod/v4/locales/ta.js
|
|
34894
34984
|
var error86 = () => {
|
|
34895
34985
|
const Sizable = {
|
|
34896
34986
|
string: { unit: "எழுத்துக்கள்", verb: "கொண்டிருக்க வேண்டும்" },
|
|
@@ -35000,7 +35090,7 @@ function ta_default2() {
|
|
|
35000
35090
|
localeError: error86()
|
|
35001
35091
|
};
|
|
35002
35092
|
}
|
|
35003
|
-
//
|
|
35093
|
+
// node_modules/zod/v4/locales/th.js
|
|
35004
35094
|
var error87 = () => {
|
|
35005
35095
|
const Sizable = {
|
|
35006
35096
|
string: { unit: "ตัวอักษร", verb: "ควรมี" },
|
|
@@ -35110,7 +35200,7 @@ function th_default2() {
|
|
|
35110
35200
|
localeError: error87()
|
|
35111
35201
|
};
|
|
35112
35202
|
}
|
|
35113
|
-
//
|
|
35203
|
+
// node_modules/zod/v4/locales/tr.js
|
|
35114
35204
|
var error88 = () => {
|
|
35115
35205
|
const Sizable = {
|
|
35116
35206
|
string: { unit: "karakter", verb: "olmalı" },
|
|
@@ -35215,7 +35305,7 @@ function tr_default2() {
|
|
|
35215
35305
|
localeError: error88()
|
|
35216
35306
|
};
|
|
35217
35307
|
}
|
|
35218
|
-
//
|
|
35308
|
+
// node_modules/zod/v4/locales/uk.js
|
|
35219
35309
|
var error89 = () => {
|
|
35220
35310
|
const Sizable = {
|
|
35221
35311
|
string: { unit: "символів", verb: "матиме" },
|
|
@@ -35324,11 +35414,11 @@ function uk_default2() {
|
|
|
35324
35414
|
};
|
|
35325
35415
|
}
|
|
35326
35416
|
|
|
35327
|
-
//
|
|
35417
|
+
// node_modules/zod/v4/locales/ua.js
|
|
35328
35418
|
function ua_default2() {
|
|
35329
35419
|
return uk_default2();
|
|
35330
35420
|
}
|
|
35331
|
-
//
|
|
35421
|
+
// node_modules/zod/v4/locales/ur.js
|
|
35332
35422
|
var error90 = () => {
|
|
35333
35423
|
const Sizable = {
|
|
35334
35424
|
string: { unit: "حروف", verb: "ہونا" },
|
|
@@ -35438,7 +35528,7 @@ function ur_default2() {
|
|
|
35438
35528
|
localeError: error90()
|
|
35439
35529
|
};
|
|
35440
35530
|
}
|
|
35441
|
-
//
|
|
35531
|
+
// node_modules/zod/v4/locales/uz.js
|
|
35442
35532
|
var error91 = () => {
|
|
35443
35533
|
const Sizable = {
|
|
35444
35534
|
string: { unit: "belgi", verb: "bo‘lishi kerak" },
|
|
@@ -35547,7 +35637,7 @@ function uz_default2() {
|
|
|
35547
35637
|
localeError: error91()
|
|
35548
35638
|
};
|
|
35549
35639
|
}
|
|
35550
|
-
//
|
|
35640
|
+
// node_modules/zod/v4/locales/vi.js
|
|
35551
35641
|
var error92 = () => {
|
|
35552
35642
|
const Sizable = {
|
|
35553
35643
|
string: { unit: "ký tự", verb: "có" },
|
|
@@ -35655,7 +35745,7 @@ function vi_default2() {
|
|
|
35655
35745
|
localeError: error92()
|
|
35656
35746
|
};
|
|
35657
35747
|
}
|
|
35658
|
-
//
|
|
35748
|
+
// node_modules/zod/v4/locales/zh-CN.js
|
|
35659
35749
|
var error93 = () => {
|
|
35660
35750
|
const Sizable = {
|
|
35661
35751
|
string: { unit: "字符", verb: "包含" },
|
|
@@ -35764,7 +35854,7 @@ function zh_CN_default2() {
|
|
|
35764
35854
|
localeError: error93()
|
|
35765
35855
|
};
|
|
35766
35856
|
}
|
|
35767
|
-
//
|
|
35857
|
+
// node_modules/zod/v4/locales/zh-TW.js
|
|
35768
35858
|
var error94 = () => {
|
|
35769
35859
|
const Sizable = {
|
|
35770
35860
|
string: { unit: "字元", verb: "擁有" },
|
|
@@ -35871,7 +35961,7 @@ function zh_TW_default2() {
|
|
|
35871
35961
|
localeError: error94()
|
|
35872
35962
|
};
|
|
35873
35963
|
}
|
|
35874
|
-
//
|
|
35964
|
+
// node_modules/zod/v4/locales/yo.js
|
|
35875
35965
|
var error95 = () => {
|
|
35876
35966
|
const Sizable = {
|
|
35877
35967
|
string: { unit: "àmi", verb: "ní" },
|
|
@@ -35978,7 +36068,7 @@ function yo_default2() {
|
|
|
35978
36068
|
localeError: error95()
|
|
35979
36069
|
};
|
|
35980
36070
|
}
|
|
35981
|
-
//
|
|
36071
|
+
// node_modules/zod/v4/core/registries.js
|
|
35982
36072
|
var _a2;
|
|
35983
36073
|
var $output2 = Symbol("ZodOutput");
|
|
35984
36074
|
var $input2 = Symbol("ZodInput");
|
|
@@ -36028,7 +36118,7 @@ function registry2() {
|
|
|
36028
36118
|
}
|
|
36029
36119
|
(_a2 = globalThis).__zod_globalRegistry ?? (_a2.__zod_globalRegistry = registry2());
|
|
36030
36120
|
var globalRegistry2 = globalThis.__zod_globalRegistry;
|
|
36031
|
-
//
|
|
36121
|
+
// node_modules/zod/v4/core/api.js
|
|
36032
36122
|
function _string2(Class3, params) {
|
|
36033
36123
|
return new Class3({
|
|
36034
36124
|
type: "string",
|
|
@@ -36948,7 +37038,7 @@ function _stringFormat2(Class3, format, fnOrRegex, _params = {}) {
|
|
|
36948
37038
|
const inst = new Class3(def);
|
|
36949
37039
|
return inst;
|
|
36950
37040
|
}
|
|
36951
|
-
//
|
|
37041
|
+
// node_modules/zod/v4/core/to-json-schema.js
|
|
36952
37042
|
function initializeContext2(params) {
|
|
36953
37043
|
let target = params?.target ?? "draft-2020-12";
|
|
36954
37044
|
if (target === "draft-4")
|
|
@@ -37293,7 +37383,7 @@ var createStandardJSONSchemaMethod2 = (schema, io, processors = {}) => (params)
|
|
|
37293
37383
|
extractDefs2(ctx, schema);
|
|
37294
37384
|
return finalize2(ctx, schema);
|
|
37295
37385
|
};
|
|
37296
|
-
//
|
|
37386
|
+
// node_modules/zod/v4/core/json-schema-processors.js
|
|
37297
37387
|
var formatMap2 = {
|
|
37298
37388
|
guid: "uuid",
|
|
37299
37389
|
url: "uri",
|
|
@@ -37838,7 +37928,7 @@ function toJSONSchema4(input, params) {
|
|
|
37838
37928
|
extractDefs2(ctx, input);
|
|
37839
37929
|
return finalize2(ctx, input);
|
|
37840
37930
|
}
|
|
37841
|
-
//
|
|
37931
|
+
// node_modules/zod/v4/core/json-schema-generator.js
|
|
37842
37932
|
class JSONSchemaGenerator2 {
|
|
37843
37933
|
get metadataRegistry() {
|
|
37844
37934
|
return this.ctx.metadataRegistry;
|
|
@@ -37897,9 +37987,9 @@ class JSONSchemaGenerator2 {
|
|
|
37897
37987
|
return plainResult;
|
|
37898
37988
|
}
|
|
37899
37989
|
}
|
|
37900
|
-
//
|
|
37990
|
+
// node_modules/zod/v4/core/json-schema.js
|
|
37901
37991
|
var exports_json_schema2 = {};
|
|
37902
|
-
//
|
|
37992
|
+
// node_modules/zod/v4/classic/schemas.js
|
|
37903
37993
|
var exports_schemas3 = {};
|
|
37904
37994
|
__export(exports_schemas3, {
|
|
37905
37995
|
xor: () => xor2,
|
|
@@ -38068,7 +38158,7 @@ __export(exports_schemas3, {
|
|
|
38068
38158
|
ZodAny: () => ZodAny2
|
|
38069
38159
|
});
|
|
38070
38160
|
|
|
38071
|
-
//
|
|
38161
|
+
// node_modules/zod/v4/classic/checks.js
|
|
38072
38162
|
var exports_checks3 = {};
|
|
38073
38163
|
__export(exports_checks3, {
|
|
38074
38164
|
uppercase: () => _uppercase2,
|
|
@@ -38102,7 +38192,7 @@ __export(exports_checks3, {
|
|
|
38102
38192
|
endsWith: () => _endsWith2
|
|
38103
38193
|
});
|
|
38104
38194
|
|
|
38105
|
-
//
|
|
38195
|
+
// node_modules/zod/v4/classic/iso.js
|
|
38106
38196
|
var exports_iso2 = {};
|
|
38107
38197
|
__export(exports_iso2, {
|
|
38108
38198
|
time: () => time5,
|
|
@@ -38143,7 +38233,7 @@ function duration5(params) {
|
|
|
38143
38233
|
return _isoDuration2(ZodISODuration2, params);
|
|
38144
38234
|
}
|
|
38145
38235
|
|
|
38146
|
-
//
|
|
38236
|
+
// node_modules/zod/v4/classic/errors.js
|
|
38147
38237
|
var initializer5 = (inst, issues) => {
|
|
38148
38238
|
$ZodError2.init(inst, issues);
|
|
38149
38239
|
inst.name = "ZodError";
|
|
@@ -38178,7 +38268,7 @@ var ZodRealError2 = $constructor2("ZodError", initializer5, {
|
|
|
38178
38268
|
Parent: Error
|
|
38179
38269
|
});
|
|
38180
38270
|
|
|
38181
|
-
//
|
|
38271
|
+
// node_modules/zod/v4/classic/parse.js
|
|
38182
38272
|
var parse6 = /* @__PURE__ */ _parse2(ZodRealError2);
|
|
38183
38273
|
var parseAsync5 = /* @__PURE__ */ _parseAsync2(ZodRealError2);
|
|
38184
38274
|
var safeParse5 = /* @__PURE__ */ _safeParse2(ZodRealError2);
|
|
@@ -38192,7 +38282,7 @@ var safeDecode5 = /* @__PURE__ */ _safeDecode2(ZodRealError2);
|
|
|
38192
38282
|
var safeEncodeAsync5 = /* @__PURE__ */ _safeEncodeAsync2(ZodRealError2);
|
|
38193
38283
|
var safeDecodeAsync5 = /* @__PURE__ */ _safeDecodeAsync2(ZodRealError2);
|
|
38194
38284
|
|
|
38195
|
-
//
|
|
38285
|
+
// node_modules/zod/v4/classic/schemas.js
|
|
38196
38286
|
var ZodType2 = /* @__PURE__ */ $constructor2("ZodType", (inst, def) => {
|
|
38197
38287
|
$ZodType2.init(inst, def);
|
|
38198
38288
|
Object.assign(inst["~standard"], {
|
|
@@ -39268,7 +39358,7 @@ function json2(params) {
|
|
|
39268
39358
|
function preprocess2(fn, schema) {
|
|
39269
39359
|
return pipe2(transform2(fn), schema);
|
|
39270
39360
|
}
|
|
39271
|
-
//
|
|
39361
|
+
// node_modules/zod/v4/classic/compat.js
|
|
39272
39362
|
var ZodIssueCode2 = {
|
|
39273
39363
|
invalid_type: "invalid_type",
|
|
39274
39364
|
too_big: "too_big",
|
|
@@ -39292,7 +39382,7 @@ function getErrorMap2() {
|
|
|
39292
39382
|
}
|
|
39293
39383
|
var ZodFirstPartyTypeKind2;
|
|
39294
39384
|
(function(ZodFirstPartyTypeKind3) {})(ZodFirstPartyTypeKind2 || (ZodFirstPartyTypeKind2 = {}));
|
|
39295
|
-
//
|
|
39385
|
+
// node_modules/zod/v4/classic/from-json-schema.js
|
|
39296
39386
|
var z2 = {
|
|
39297
39387
|
...exports_schemas3,
|
|
39298
39388
|
...exports_checks3,
|
|
@@ -39753,7 +39843,7 @@ function fromJSONSchema4(schema, params) {
|
|
|
39753
39843
|
};
|
|
39754
39844
|
return convertSchema2(schema, ctx);
|
|
39755
39845
|
}
|
|
39756
|
-
//
|
|
39846
|
+
// node_modules/zod/v4/classic/coerce.js
|
|
39757
39847
|
var exports_coerce2 = {};
|
|
39758
39848
|
__export(exports_coerce2, {
|
|
39759
39849
|
string: () => string7,
|
|
@@ -39778,21 +39868,27 @@ function date9(params) {
|
|
|
39778
39868
|
return _coercedDate2(ZodDate2, params);
|
|
39779
39869
|
}
|
|
39780
39870
|
|
|
39781
|
-
//
|
|
39871
|
+
// node_modules/zod/v4/classic/external.js
|
|
39782
39872
|
config2(en_default2());
|
|
39783
39873
|
// src/project/util/git.ts
|
|
39784
39874
|
import { execSync } from "node:child_process";
|
|
39875
|
+
var getPathnameFromGitUrl = (url4) => {
|
|
39876
|
+
const _url3 = new URL(url4.replace(/\.git$/, ""));
|
|
39877
|
+
const pathname = _url3.pathname.replace(/^\/+/, "").replace(/\/+$/, "");
|
|
39878
|
+
return pathname;
|
|
39879
|
+
};
|
|
39785
39880
|
var getGitPathname = (repoPath) => {
|
|
39786
39881
|
try {
|
|
39787
39882
|
const url4 = execSync("git config --get remote.origin.url", { cwd: repoPath, encoding: "utf-8" }).trim();
|
|
39788
39883
|
if (url4) {
|
|
39789
|
-
|
|
39790
|
-
|
|
39791
|
-
|
|
39884
|
+
return {
|
|
39885
|
+
url: url4,
|
|
39886
|
+
pathname: getPathnameFromGitUrl(url4)
|
|
39887
|
+
};
|
|
39792
39888
|
}
|
|
39793
39889
|
return null;
|
|
39794
39890
|
} catch (err) {
|
|
39795
|
-
console.warn(`[getGitPathname] Failed to get git remote url for ${repoPath}
|
|
39891
|
+
console.warn(`[getGitPathname] Failed to get git remote url for ${repoPath}:`, err);
|
|
39796
39892
|
return null;
|
|
39797
39893
|
}
|
|
39798
39894
|
};
|
|
@@ -39814,16 +39910,18 @@ app.route({
|
|
|
39814
39910
|
let { filepath, repo, name } = ctx.query;
|
|
39815
39911
|
if (!filepath)
|
|
39816
39912
|
ctx.throw(400, "filepath 不能为空");
|
|
39913
|
+
let link = "";
|
|
39817
39914
|
if (!repo) {
|
|
39818
39915
|
const gitPathname = getGitPathname(filepath);
|
|
39819
39916
|
if (gitPathname) {
|
|
39820
|
-
repo = gitPathname;
|
|
39917
|
+
repo = gitPathname.pathname;
|
|
39918
|
+
link = gitPathname.url;
|
|
39821
39919
|
} else {
|
|
39822
39920
|
const pathParts = filepath.split("/");
|
|
39823
39921
|
repo = pathParts[pathParts.length - 1];
|
|
39824
39922
|
}
|
|
39825
39923
|
}
|
|
39826
|
-
const info = await manager.addProject({ path: filepath, repo, name });
|
|
39924
|
+
const info = await manager.addProject({ path: filepath, repo, name, link: link || (repo ? `https://cnb.cool/${repo}` : undefined) });
|
|
39827
39925
|
ctx.body = { success: true, data: info };
|
|
39828
39926
|
}).addTo(app);
|
|
39829
39927
|
app.route({
|
|
@@ -40042,11 +40140,135 @@ app.route({
|
|
|
40042
40140
|
}
|
|
40043
40141
|
}).addTo(app);
|
|
40044
40142
|
|
|
40143
|
+
// src/routes/project-init.ts
|
|
40144
|
+
import fs4 from "node:fs";
|
|
40145
|
+
import path5 from "node:path";
|
|
40146
|
+
import { execSync as execSync2 } from "node:child_process";
|
|
40147
|
+
var DEFAULT_ROOT_PATH = "/workspace/projects";
|
|
40148
|
+
var getProjectPaths = (ctx) => {
|
|
40149
|
+
const rootPath = path5.resolve(ctx.query.rootPath || DEFAULT_ROOT_PATH);
|
|
40150
|
+
if (!fs4.existsSync(rootPath)) {
|
|
40151
|
+
ctx.throw(400, "rootPath 指定的目录不存在");
|
|
40152
|
+
}
|
|
40153
|
+
const projectPaths = [];
|
|
40154
|
+
try {
|
|
40155
|
+
const entries = fs4.readdirSync(rootPath, { withFileTypes: true });
|
|
40156
|
+
for (const entry of entries) {
|
|
40157
|
+
if (!entry.isDirectory())
|
|
40158
|
+
continue;
|
|
40159
|
+
const fullPath = path5.join(rootPath, entry.name);
|
|
40160
|
+
if (entry.name === "node_modules" || entry.name.startsWith("."))
|
|
40161
|
+
continue;
|
|
40162
|
+
if (fs4.existsSync(path5.join(fullPath, ".git"))) {
|
|
40163
|
+
projectPaths.push(fullPath);
|
|
40164
|
+
}
|
|
40165
|
+
}
|
|
40166
|
+
} catch (err) {
|
|
40167
|
+
console.warn(`[project-init] Failed to read root directory ${rootPath}:`, err);
|
|
40168
|
+
}
|
|
40169
|
+
return {
|
|
40170
|
+
rootPath,
|
|
40171
|
+
projectPaths
|
|
40172
|
+
};
|
|
40173
|
+
};
|
|
40174
|
+
app.route({
|
|
40175
|
+
path: "project",
|
|
40176
|
+
key: "init",
|
|
40177
|
+
description: "初始化项目,通过root目录,搜索当前有git的项目列表,并将其注册到系统中",
|
|
40178
|
+
middleware: ["auth-admin"],
|
|
40179
|
+
metadata: {
|
|
40180
|
+
args: {
|
|
40181
|
+
rootPath: exports_external2.string().optional().describe("搜索项目的根目录绝对路径,默认为 /workspace/projects")
|
|
40182
|
+
}
|
|
40183
|
+
}
|
|
40184
|
+
}).define(async (ctx) => {
|
|
40185
|
+
const { rootPath, projectPaths } = getProjectPaths(ctx);
|
|
40186
|
+
const results = [];
|
|
40187
|
+
for (const projectPath of projectPaths) {
|
|
40188
|
+
try {
|
|
40189
|
+
const gitRepo = getGitPathname(projectPath);
|
|
40190
|
+
const repo = gitRepo?.pathname || path5.basename(projectPath);
|
|
40191
|
+
const name = path5.basename(projectPath);
|
|
40192
|
+
await manager.addProject({ path: projectPath, repo, name, link: gitRepo?.url });
|
|
40193
|
+
results.push({ path: projectPath, repo, success: true });
|
|
40194
|
+
console.log(`[project-init] Added project: ${projectPath}, repo: ${repo}`);
|
|
40195
|
+
} catch (err) {
|
|
40196
|
+
const error49 = err instanceof Error ? err.message : String(err);
|
|
40197
|
+
results.push({ path: projectPath, repo: null, success: false, error: error49 });
|
|
40198
|
+
console.error(`[project-init] Failed to add project ${projectPath}:`, err);
|
|
40199
|
+
}
|
|
40200
|
+
}
|
|
40201
|
+
ctx.body = {
|
|
40202
|
+
rootPath,
|
|
40203
|
+
totalFound: projectPaths.length,
|
|
40204
|
+
results
|
|
40205
|
+
};
|
|
40206
|
+
}).addTo(app);
|
|
40207
|
+
app.route({
|
|
40208
|
+
path: "project",
|
|
40209
|
+
key: "list-projects",
|
|
40210
|
+
description: "列出当前工作区已注册的项目",
|
|
40211
|
+
middleware: ["auth-admin"],
|
|
40212
|
+
metadata: {
|
|
40213
|
+
args: {
|
|
40214
|
+
rootPath: exports_external2.string().optional().describe("项目根目录绝对路径,默认为 /workspace/projects,指定后只列出该目录下的项目")
|
|
40215
|
+
}
|
|
40216
|
+
}
|
|
40217
|
+
}).define(async (ctx) => {
|
|
40218
|
+
const { rootPath, projectPaths } = getProjectPaths(ctx);
|
|
40219
|
+
ctx.body = {
|
|
40220
|
+
rootPath,
|
|
40221
|
+
list: projectPaths
|
|
40222
|
+
};
|
|
40223
|
+
}).addTo(app);
|
|
40224
|
+
app.route({
|
|
40225
|
+
path: "project",
|
|
40226
|
+
key: "clone-cnb",
|
|
40227
|
+
description: "clone 一个项目到projects目录下,并注册到系统中。",
|
|
40228
|
+
middleware: ["auth-admin"],
|
|
40229
|
+
metadata: {
|
|
40230
|
+
args: {
|
|
40231
|
+
filepath: exports_external2.string().optional().describe("新项目根目录的绝对路径,默认在 /workspace/projects 下以仓库名创建子目录"),
|
|
40232
|
+
repo: exports_external2.string().describe("代码仓库标识,用于搜索结果展示和过滤,格式如 owner/repo,例如 kevisual/cnb,必填")
|
|
40233
|
+
}
|
|
40234
|
+
}
|
|
40235
|
+
}).define(async (ctx) => {
|
|
40236
|
+
const { filepath = DEFAULT_ROOT_PATH, repo = "" } = ctx.query;
|
|
40237
|
+
let cloneRepoUrl = "";
|
|
40238
|
+
if (repo?.startsWith("http")) {
|
|
40239
|
+
cloneRepoUrl = repo;
|
|
40240
|
+
} else if (repo) {
|
|
40241
|
+
cloneRepoUrl = `https://cnb.cool/${repo}`;
|
|
40242
|
+
} else {
|
|
40243
|
+
ctx.throw(400, "repo 参数不能为空,且必须是完整的 URL 或者 owner/repo 格式");
|
|
40244
|
+
}
|
|
40245
|
+
const name = getPathnameFromGitUrl(cloneRepoUrl);
|
|
40246
|
+
if (!name) {
|
|
40247
|
+
ctx.throw(400, "无法从 repo 参数解析出项目名称,请检查 repo 格式是否正确");
|
|
40248
|
+
}
|
|
40249
|
+
const targetPath = path5.join(filepath, name);
|
|
40250
|
+
if (fs4.existsSync(targetPath)) {
|
|
40251
|
+
ctx.throw(400, `目标路径已存在: ${targetPath}`);
|
|
40252
|
+
}
|
|
40253
|
+
const cloneCmd = `git clone ${cloneRepoUrl} ${targetPath}`;
|
|
40254
|
+
try {
|
|
40255
|
+
console.log(`[project-clone] Cloning repo ${cloneRepoUrl} to ${targetPath}...`);
|
|
40256
|
+
execSync2(cloneCmd, { stdio: "inherit" });
|
|
40257
|
+
console.log(`[project-clone] Clone successful, adding project...`);
|
|
40258
|
+
const info = await manager.addProject({ path: targetPath, repo: name, name, link: cloneRepoUrl });
|
|
40259
|
+
ctx.body = info;
|
|
40260
|
+
} catch (err) {
|
|
40261
|
+
const error49 = err instanceof Error ? err.message : String(err);
|
|
40262
|
+
console.error(`[project-clone] Failed to clone and add project from ${cloneRepoUrl}:`, err);
|
|
40263
|
+
ctx.throw(500, `Failed to clone and add project: ${error49}`);
|
|
40264
|
+
}
|
|
40265
|
+
}).addTo(app);
|
|
40266
|
+
|
|
40045
40267
|
// src/index.ts
|
|
40046
40268
|
if (false) {}
|
|
40047
40269
|
await manager.init();
|
|
40048
40270
|
|
|
40049
|
-
//
|
|
40271
|
+
// node_modules/@kevisual/remote-app/dist/app.js
|
|
40050
40272
|
var __create3 = Object.create;
|
|
40051
40273
|
var __getProtoOf3 = Object.getPrototypeOf;
|
|
40052
40274
|
var __defProp3 = Object.defineProperty;
|