@cannbot-ai/install-helper 1.1.15-beta.0 → 1.1.15
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 +30 -0
- package/dist/index.js.map +1 -1
- package/package.json +6 -6
package/dist/index.js
CHANGED
|
@@ -701,6 +701,27 @@ var init_fs = __esm({
|
|
|
701
701
|
}
|
|
702
702
|
});
|
|
703
703
|
|
|
704
|
+
// src/embedded-config.json
|
|
705
|
+
var embedded_config_default;
|
|
706
|
+
var init_embedded_config = __esm({
|
|
707
|
+
"src/embedded-config.json"() {
|
|
708
|
+
embedded_config_default = {
|
|
709
|
+
scanDirs: [
|
|
710
|
+
"ops",
|
|
711
|
+
"model",
|
|
712
|
+
"graph",
|
|
713
|
+
"infra",
|
|
714
|
+
"runtime",
|
|
715
|
+
"tools"
|
|
716
|
+
],
|
|
717
|
+
pluginDirs: [
|
|
718
|
+
"plugins-official"
|
|
719
|
+
],
|
|
720
|
+
cacheTtlHours: 24
|
|
721
|
+
};
|
|
722
|
+
}
|
|
723
|
+
});
|
|
724
|
+
|
|
704
725
|
// src/core/scanner.ts
|
|
705
726
|
import { existsSync as existsSync4, readdirSync, readFileSync as readFileSync2, mkdirSync } from "fs";
|
|
706
727
|
import { join as join3, dirname as dirname3 } from "path";
|
|
@@ -724,6 +745,14 @@ function loadScanConfig() {
|
|
|
724
745
|
} catch {
|
|
725
746
|
}
|
|
726
747
|
}
|
|
748
|
+
const embedded = embedded_config_default;
|
|
749
|
+
if (Array.isArray(embedded.scanDirs) && embedded.scanDirs.length > 0) {
|
|
750
|
+
return {
|
|
751
|
+
skillDirs: embedded.scanDirs,
|
|
752
|
+
pluginDirs: Array.isArray(embedded.pluginDirs) && embedded.pluginDirs.length > 0 ? embedded.pluginDirs : ["plugins-official", "plugins-community"],
|
|
753
|
+
cacheTtlMs: (embedded.cacheTtlHours || 24) * 60 * 60 * 1e3
|
|
754
|
+
};
|
|
755
|
+
}
|
|
727
756
|
return {
|
|
728
757
|
skillDirs: ["ops", "model", "graph", "infra", "runtime"],
|
|
729
758
|
pluginDirs: ["plugins-official", "plugins-community"],
|
|
@@ -897,6 +926,7 @@ var init_scanner = __esm({
|
|
|
897
926
|
init_paths();
|
|
898
927
|
init_fs();
|
|
899
928
|
init_fs_helpers();
|
|
929
|
+
init_embedded_config();
|
|
900
930
|
__filename2 = fileURLToPath2(import.meta.url);
|
|
901
931
|
__dirname2 = dirname3(__filename2);
|
|
902
932
|
EXCLUDE_DIRS = /* @__PURE__ */ new Set([
|