bluelamp 6.0.2 → 6.2.0
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/bluelamp-vscode-base +1 -1
- package/lib/auth/InteractiveLogin.js +1 -1
- package/lib/auth/PortalAuthClient.js +1 -1
- package/lib/auth/TokenManager.js +1 -1
- package/lib/mcp-server/index.cjs +1 -1
- package/lib/mcp-server/portal-api-client.cjs +1 -1
- package/package.json +1 -1
- package/scripts/setup-mcps.js +1 -1
package/package.json
CHANGED
package/scripts/setup-mcps.js
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
|
-
const fs=require("fs"),path=require("path"),os=require("os"),crypto=require("crypto"),MCP_JSON_PATH=path.join(os.homedir(),".mcp.json"),BLUELAMP_DIR=path.join(os.homedir(),".bluelamp"),REGISTRY_PATH=path.join(BLUELAMP_DIR,"registry.json"),VAULT_KEY_PATH=path.join(BLUELAMP_DIR,"vault.key"),PASSWORD_MANAGER_ENTRY=path.join(__dirname,"..","lib","mcp-password-manager","index.js"),GMAIL_MCP_ENTRY=path.join(__dirname,"..","lib","mcp-gmail","index.js");function setup(){if(console.log("\n📦 BlueLamp MCP セットアップ開始...\n"),fs.existsSync(BLUELAMP_DIR)||fs.mkdirSync(BLUELAMP_DIR,{recursive:!0,mode:448}),!fs.existsSync(VAULT_KEY_PATH)){const e=crypto.randomBytes(32).toString("hex");fs.writeFileSync(VAULT_KEY_PATH,e,{mode:384}),console.log(" 🔑 暗号化キーを生成しました (~/.bluelamp/vault.key)")}const e=path.join(os.homedir(),".config","gmail-mcp"),s=path.join(e,"tokens");fs.existsSync(s)||fs.mkdirSync(s,{recursive:!0,mode:448});const o=path.join(e,"credentials.json"),n=path.join(__dirname,"..","lib","mcp-gmail","credentials.json");!fs.existsSync(o)&&fs.existsSync(n)&&(fs.copyFileSync(n,o),console.log(" 📧 Gmail OAuth設定をコピーしました"));const
|
|
2
|
+
const fs=require("fs"),path=require("path"),os=require("os"),crypto=require("crypto"),MCP_JSON_PATH=path.join(os.homedir(),".mcp.json"),BLUELAMP_DIR=path.join(os.homedir(),".bluelamp"),REGISTRY_PATH=path.join(BLUELAMP_DIR,"registry.json"),VAULT_KEY_PATH=path.join(BLUELAMP_DIR,"vault.key"),PASSWORD_MANAGER_ENTRY=path.join(__dirname,"..","lib","mcp-password-manager","index.js"),GMAIL_MCP_ENTRY=path.join(__dirname,"..","lib","mcp-gmail","index.js");function setup(){if(console.log("\n📦 BlueLamp MCP セットアップ開始...\n"),fs.existsSync(BLUELAMP_DIR)||fs.mkdirSync(BLUELAMP_DIR,{recursive:!0,mode:448}),!fs.existsSync(VAULT_KEY_PATH)){const e=crypto.randomBytes(32).toString("hex");fs.writeFileSync(VAULT_KEY_PATH,e,{mode:384}),console.log(" 🔑 暗号化キーを生成しました (~/.bluelamp/vault.key)")}const e=path.join(os.homedir(),".config","gmail-mcp"),s=path.join(e,"tokens");fs.existsSync(s)||fs.mkdirSync(s,{recursive:!0,mode:448});const o=path.join(e,"credentials.json"),n=path.join(__dirname,"..","lib","mcp-gmail","credentials.json");!fs.existsSync(o)&&fs.existsSync(n)&&(fs.copyFileSync(n,o),console.log(" 📧 Gmail OAuth設定をコピーしました"));const r=path.join(os.homedir(),".playwright-profiles");fs.existsSync(r)||fs.mkdirSync(r,{recursive:!0});let i={};if(fs.existsSync(REGISTRY_PATH))try{i=JSON.parse(fs.readFileSync(REGISTRY_PATH,"utf-8")),console.log(" 📋 既存registry.jsonを検出、マージします")}catch{console.log(" ⚠️ registry.json解析失敗、新規作成します"),i={}}fs.writeFileSync(REGISTRY_PATH,JSON.stringify(i,null,2)+"\n"),console.log(`\n 📋 registry.json 更新完了 (${Object.keys(i).length}サービス)`);let l={mcpServers:{}};if(fs.existsSync(MCP_JSON_PATH))try{l=JSON.parse(fs.readFileSync(MCP_JSON_PATH,"utf8")),l.mcpServers||(l.mcpServers={})}catch{console.log(" ⚠️ ~/.mcp.json 解析失敗、再作成します"),l={mcpServers:{}}}const c=["playwright","playwright-2","playwright-3","password-manager","gmail","ms365","poc-gateway"];let t=0;for(const e of c)l.mcpServers[e]&&(delete l.mcpServers[e],t++);t>0&&console.log(` 🧹 ~/.mcp.json から ${t}個の個別MCP登録を削除`),l.mcpServers.bluelamp||(l.mcpServers.bluelamp={command:"bluelamp1",args:[]},console.log(" 🚀 bluelamp ゲートウェイを ~/.mcp.json に登録")),fs.writeFileSync(MCP_JSON_PATH,JSON.stringify(l,null,2)+"\n"),console.log(" ✅ ~/.mcp.json 更新完了"),console.log("\n✨ BlueLamp MCP セットアップ完了"),console.log(" Gateway統合: bluelamp 1プロセスで全MCPをプロキシ"),console.log(" MCPのインストール: install_from_store + @BlueLampセットアップ で登録してください\n")}setup();
|