bluelamp 4.0.5 → 4.0.6
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 +258 -0
- package/bin/bluelamp-vscode1 +2 -0
- package/bin/bluelamp-vscode10 +2 -0
- package/bin/bluelamp-vscode11 +2 -0
- package/bin/bluelamp-vscode12 +2 -0
- package/bin/bluelamp-vscode13 +2 -0
- package/bin/bluelamp-vscode14 +2 -0
- package/bin/bluelamp-vscode15 +2 -0
- package/bin/bluelamp-vscode16 +2 -0
- package/bin/bluelamp-vscode17 +2 -0
- package/bin/bluelamp-vscode18 +2 -0
- package/bin/bluelamp-vscode2 +2 -0
- package/bin/bluelamp-vscode3 +2 -0
- package/bin/bluelamp-vscode4 +2 -0
- package/bin/bluelamp-vscode5 +2 -0
- package/bin/bluelamp-vscode6 +2 -0
- package/bin/bluelamp-vscode7 +2 -0
- package/bin/bluelamp-vscode8 +2 -0
- package/bin/bluelamp-vscode9 +2 -0
- package/lib/auth/PortalAuthClient.js +1 -1
- package/lib/mcp-server/index.cjs +57 -25
- package/lib/mcp-server/portal-api-client.cjs +37 -10
- package/lib/utils/logger.js +83 -0
- package/package.json +33 -25
- package/scripts/generate-commands.js +10 -15
- package/bin/bluelamp-base +0 -200
- package/bin/bluelamp-hook +0 -49
- package/bin/bluelamp1 +0 -2
- package/bin/bluelamp10 +0 -2
- package/bin/bluelamp11 +0 -2
- package/bin/bluelamp12 +0 -2
- package/bin/bluelamp13 +0 -2
- package/bin/bluelamp14 +0 -2
- package/bin/bluelamp15 +0 -2
- package/bin/bluelamp16 +0 -2
- package/bin/bluelamp17 +0 -2
- package/bin/bluelamp18 +0 -2
- package/bin/bluelamp2 +0 -2
- package/bin/bluelamp3 +0 -2
- package/bin/bluelamp4 +0 -2
- package/bin/bluelamp5 +0 -2
- package/bin/bluelamp6 +0 -2
- package/bin/bluelamp7 +0 -2
- package/bin/bluelamp8 +0 -2
- package/bin/bluelamp9 +0 -2
- package/lib/mcp-server/fetch-prompt.js +0 -61
- package/scripts/setup-hook.js +0 -98
package/scripts/setup-hook.js
DELETED
|
@@ -1,98 +0,0 @@
|
|
|
1
|
-
#!/usr/bin/env node
|
|
2
|
-
|
|
3
|
-
/**
|
|
4
|
-
* BlueLamp Hook セットアップスクリプト
|
|
5
|
-
* Claude Code の settings.json に SessionStart Hook を追加
|
|
6
|
-
*/
|
|
7
|
-
|
|
8
|
-
const fs = require('fs');
|
|
9
|
-
const path = require('path');
|
|
10
|
-
const os = require('os');
|
|
11
|
-
|
|
12
|
-
const claudeSettingsDir = path.join(os.homedir(), '.claude');
|
|
13
|
-
const claudeSettingsPath = path.join(claudeSettingsDir, 'settings.json');
|
|
14
|
-
|
|
15
|
-
// bluelamp-hook コマンドのパス(グローバルインストール時)
|
|
16
|
-
const hookCommand = 'bluelamp-hook';
|
|
17
|
-
|
|
18
|
-
function setupHook() {
|
|
19
|
-
console.log('🔧 BlueLamp SessionStart Hook をセットアップ中...');
|
|
20
|
-
|
|
21
|
-
// .claude ディレクトリがなければ作成
|
|
22
|
-
if (!fs.existsSync(claudeSettingsDir)) {
|
|
23
|
-
fs.mkdirSync(claudeSettingsDir, { recursive: true });
|
|
24
|
-
console.log(` Created: ${claudeSettingsDir}`);
|
|
25
|
-
}
|
|
26
|
-
|
|
27
|
-
// 既存の settings.json を読み込み
|
|
28
|
-
let settings = {};
|
|
29
|
-
if (fs.existsSync(claudeSettingsPath)) {
|
|
30
|
-
try {
|
|
31
|
-
const content = fs.readFileSync(claudeSettingsPath, 'utf-8');
|
|
32
|
-
settings = JSON.parse(content);
|
|
33
|
-
console.log(' 既存の settings.json を読み込みました');
|
|
34
|
-
} catch (e) {
|
|
35
|
-
console.log(' settings.json の解析に失敗、新規作成します');
|
|
36
|
-
}
|
|
37
|
-
}
|
|
38
|
-
|
|
39
|
-
// hooks が未定義なら初期化
|
|
40
|
-
if (!settings.hooks) {
|
|
41
|
-
settings.hooks = {};
|
|
42
|
-
}
|
|
43
|
-
|
|
44
|
-
// SessionStart hooks が未定義なら初期化
|
|
45
|
-
if (!settings.hooks.SessionStart) {
|
|
46
|
-
settings.hooks.SessionStart = [];
|
|
47
|
-
}
|
|
48
|
-
|
|
49
|
-
// BlueLamp hook が既に存在するかチェック
|
|
50
|
-
const existingHook = settings.hooks.SessionStart.find(
|
|
51
|
-
h => h.hooks && h.hooks.some(hook => hook.command === hookCommand)
|
|
52
|
-
);
|
|
53
|
-
|
|
54
|
-
if (existingHook) {
|
|
55
|
-
console.log('✅ BlueLamp Hook は既にセットアップ済みです');
|
|
56
|
-
return;
|
|
57
|
-
}
|
|
58
|
-
|
|
59
|
-
// BlueLamp SessionStart Hook を追加
|
|
60
|
-
settings.hooks.SessionStart.push({
|
|
61
|
-
matcher: "",
|
|
62
|
-
hooks: [
|
|
63
|
-
{
|
|
64
|
-
type: "command",
|
|
65
|
-
command: hookCommand
|
|
66
|
-
}
|
|
67
|
-
]
|
|
68
|
-
});
|
|
69
|
-
|
|
70
|
-
// settings.json を保存
|
|
71
|
-
fs.writeFileSync(claudeSettingsPath, JSON.stringify(settings, null, 2));
|
|
72
|
-
console.log(`✅ SessionStart Hook を追加しました: ${claudeSettingsPath}`);
|
|
73
|
-
console.log('');
|
|
74
|
-
console.log('📝 追加された設定:');
|
|
75
|
-
console.log(JSON.stringify(settings.hooks.SessionStart, null, 2));
|
|
76
|
-
}
|
|
77
|
-
|
|
78
|
-
try {
|
|
79
|
-
setupHook();
|
|
80
|
-
} catch (error) {
|
|
81
|
-
console.error('❌ Hook セットアップエラー:', error.message);
|
|
82
|
-
console.log('');
|
|
83
|
-
console.log('手動でセットアップするには:');
|
|
84
|
-
console.log(`1. ${claudeSettingsPath} を開く`);
|
|
85
|
-
console.log('2. 以下を追加:');
|
|
86
|
-
console.log(`
|
|
87
|
-
{
|
|
88
|
-
"hooks": {
|
|
89
|
-
"SessionStart": [
|
|
90
|
-
{
|
|
91
|
-
"matcher": "",
|
|
92
|
-
"hooks": [{ "type": "command", "command": "${hookCommand}" }]
|
|
93
|
-
}
|
|
94
|
-
]
|
|
95
|
-
}
|
|
96
|
-
}
|
|
97
|
-
`);
|
|
98
|
-
}
|