@seed-design/mcp 0.1.9-20250806034801 → 0.1.9-20250806055925
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/bin/index.mjs +3 -7
- package/package.json +1 -1
- package/src/config.ts +4 -6
package/bin/index.mjs
CHANGED
|
@@ -681,15 +681,11 @@ var version = "0.1.9-20250806034801";
|
|
|
681
681
|
|
|
682
682
|
// Config loader
|
|
683
683
|
async function loadConfig(configPath) {
|
|
684
|
-
const explorer = cosmiconfig("mcp"
|
|
685
|
-
|
|
686
|
-
configPath
|
|
687
|
-
]
|
|
688
|
-
});
|
|
689
|
-
const searchResult = await explorer.search();
|
|
684
|
+
const explorer = cosmiconfig("mcp");
|
|
685
|
+
const searchResult = await explorer.load(configPath);
|
|
690
686
|
if (!searchResult) {
|
|
691
687
|
logger.error(`Config file not found: ${configPath}`);
|
|
692
|
-
return
|
|
688
|
+
return null;
|
|
693
689
|
}
|
|
694
690
|
return searchResult.config;
|
|
695
691
|
}
|
package/package.json
CHANGED
package/src/config.ts
CHANGED
|
@@ -8,17 +8,15 @@ export interface McpConfig {
|
|
|
8
8
|
}
|
|
9
9
|
|
|
10
10
|
// Config loader
|
|
11
|
-
export async function loadConfig(configPath: string): Promise<McpConfig> {
|
|
12
|
-
const explorer = cosmiconfig("mcp"
|
|
13
|
-
searchPlaces: [configPath],
|
|
14
|
-
});
|
|
11
|
+
export async function loadConfig(configPath: string): Promise<McpConfig | null> {
|
|
12
|
+
const explorer = cosmiconfig("mcp");
|
|
15
13
|
|
|
16
|
-
const searchResult = await explorer.
|
|
14
|
+
const searchResult = await explorer.load(configPath);
|
|
17
15
|
|
|
18
16
|
if (!searchResult) {
|
|
19
17
|
logger.error(`Config file not found: ${configPath}`);
|
|
20
18
|
|
|
21
|
-
return
|
|
19
|
+
return null;
|
|
22
20
|
}
|
|
23
21
|
|
|
24
22
|
return searchResult.config;
|