Skip to content

Commit 1f32c30

Browse files
author
Pedro Rodrigues
committed
add support to vscode insiders
1 parent 9aab64d commit 1f32c30

File tree

2 files changed

+28
-12
lines changed

2 files changed

+28
-12
lines changed

src/commands/constants.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,7 @@
33
CLIENT_CLAUDE_CODE = "claude-code"
44
CLIENT_CURSOR = "cursor"
55
CLIENT_VSCODE = "vscode"
6+
CLIENT_VSCODE_INSIDERS = "vscode-insiders"
67
CLIENT_WINDSURF = "windsurf"
78
CLIENT_LM_STUDIO = "lm-studio"
89
CLIENT_GEMINI = "gemini"
@@ -18,6 +19,7 @@
1819
CLIENT_CLAUDE_CODE,
1920
CLIENT_CURSOR,
2021
CLIENT_VSCODE,
22+
CLIENT_VSCODE_INSIDERS,
2123
CLIENT_WINDSURF,
2224
CLIENT_LM_STUDIO,
2325
CLIENT_GEMINI,

src/commands/init.py

Lines changed: 26 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,7 @@
1111
CLIENT_CLAUDE_CODE,
1212
CLIENT_CURSOR,
1313
CLIENT_VSCODE,
14+
CLIENT_VSCODE_INSIDERS,
1415
CLIENT_WINDSURF,
1516
CLIENT_LM_STUDIO,
1617
CLIENT_GEMINI,
@@ -38,9 +39,14 @@
3839
"linux": "~/.cursor/mcp.json",
3940
},
4041
CLIENT_VSCODE: {
41-
"darwin": "~/Library/Application Support/Code/User/settings.json",
42-
"win32": "%APPDATA%\\Code\\User\\settings.json",
43-
"linux": "~/.config/Code/User/settings.json",
42+
"darwin": "~/Library/Application Support/Code/User/mcp.json",
43+
"win32": "%APPDATA%\\Code\\User\\mcp.json",
44+
"linux": "~/.config/Code/User/mcp.json",
45+
},
46+
CLIENT_VSCODE_INSIDERS: {
47+
"darwin": "~/Library/Application Support/Code - Insiders/User/mcp.json",
48+
"win32": "%APPDATA%\\Code - Insiders\\User\\mcp.json",
49+
"linux": "~/.config/Code - Insiders/User/mcp.json",
4450
},
4551
CLIENT_WINDSURF: {
4652
"darwin": "~/.windsurf/mcp.json",
@@ -82,7 +88,15 @@
8288
}
8389
},
8490
CLIENT_VSCODE: {
85-
"mcp.mcpServers": {
91+
"servers": {
92+
"singlestore-mcp-server": {
93+
"command": "uvx",
94+
"args": ["singlestore-mcp-server", "start"],
95+
}
96+
}
97+
},
98+
CLIENT_VSCODE_INSIDERS: {
99+
"servers": {
86100
"singlestore-mcp-server": {
87101
"command": "uvx",
88102
"args": ["singlestore-mcp-server", "start"],
@@ -240,12 +254,12 @@ def update_client_config(client: str) -> tuple[bool, Optional[dict]]:
240254
try:
241255
existing_config = json.load(f)
242256
# Merge the configs based on client type
243-
if client == CLIENT_VSCODE:
257+
if client in [CLIENT_VSCODE, CLIENT_VSCODE_INSIDERS]:
244258
# VS Code uses a different structure in settings.json
245-
if "mcp.mcpServers" not in existing_config:
246-
existing_config["mcp.mcpServers"] = {}
247-
existing_config["mcp.mcpServers"]["singlestore-mcp-server"] = (
248-
config_data["mcp.mcpServers"]["singlestore-mcp-server"]
259+
if "servers" not in existing_config:
260+
existing_config["servers"] = {}
261+
existing_config["servers"]["singlestore-mcp-server"] = (
262+
config_data["servers"]["singlestore-mcp-server"]
249263
)
250264
elif client in [
251265
CLIENT_CLAUDE_DESKTOP,
@@ -322,12 +336,12 @@ def init_command(client: str) -> int:
322336
logger.info(f"Claude Code output: {config_data['output']}")
323337
else:
324338
logger.info(f"CLI command executed: {config_data['cli_command']}")
325-
elif client == CLIENT_VSCODE:
326-
mcp_server_config = config_data.get("mcp.mcpServers", {}).get(
339+
elif client in [CLIENT_VSCODE, CLIENT_VSCODE_INSIDERS]:
340+
mcp_server_config = config_data.get("servers", {}).get(
327341
"singlestore-mcp-server", {}
328342
)
329343
config_display = {
330-
"mcp.mcpServers": {
344+
"servers": {
331345
"...": "...",
332346
"singlestore-mcp-server": mcp_server_config,
333347
}

0 commit comments

Comments
 (0)