- 拓展/: MCP配置向导、PowerShell工具、mcp-auto-loader 纳入版本管理 - guide.html: badges 从模糊 "90+" 改为精确 "92 Skills | 18 Agents | 34 Hooks"
30 lines
887 B
JavaScript
30 lines
887 B
JavaScript
#!/usr/bin/env node
|
|
const fs = require('fs');
|
|
const path = require('path');
|
|
const os = require('os');
|
|
const { execSync } = require('child_process');
|
|
|
|
console.log('MCP Auto Loader v1.0');
|
|
console.log('====================\n');
|
|
|
|
const outputDir = 'E:\';
|
|
const services = {
|
|
playwright: '@modelcontextprotocol/server-playwright',
|
|
'chrome-devtools': '@executeautomation/chrome-devtools-mcp',
|
|
github: '@modelcontextprotocol/server-github',
|
|
slack: '@modelcontextprotocol/server-slack',
|
|
linear: '@modelcontextprotocol/server-linear'
|
|
};
|
|
|
|
const mcpServers = {};
|
|
for (const [name, pkg] of Object.entries(services)) {
|
|
mcpServers[name] = {
|
|
command: 'cmd',
|
|
args: ['/c', 'npx', '-y', pkg]
|
|
};
|
|
}
|
|
|
|
const configPath = path.join(outputDir, 'mcp-configs-summary.json');
|
|
fs.writeFileSync(configPath, JSON.stringify({ mcpServers }, null, 2));
|
|
console.log('Config saved to:', configPath);
|