Skip to content

Claude Marketplace Plugin Support #439

@jchaconTAG

Description

@jchaconTAG

fix: OS-agnostic plugin setup and marketplace source for Claude Desktop

Summary

Four small fixes to make the Claude Desktop plugin work on Windows and enable proper GitHub-based marketplace installation. All changes are backward-compatible with macOS/Linux.


Problems

1. setup.sh hardcodes Unix venv paths — breaks on Windows

The script uses .venv/bin/python throughout. On Windows, uv creates the venv at .venv\Scripts\python.exe. This causes the idempotency check, uv pip install --python, and the final import verification to all fail silently or with misleading errors.

2. .mcp.json hardcodes a Unix Python path

"command": "${CLAUDE_PLUGIN_ROOT}/.venv/bin/python"

This path does not exist on Windows, so the MCP server never starts for Windows users.

3. marketplace.json source points to "./"

"source": "./"

A relative local path only works when the plugin is already on disk. For Claude Desktop to install this plugin from a marketplace or URL, source needs to point to the GitHub repo.

4. plugin.json does not reference hooks or mcp

Claude Desktop reads plugin.json as the manifest. Without hooks and mcp fields pointing to hooks/hooks.json and .mcp.json, the SessionStart scripts and MCP server config are invisible to the host unless it already knows where to look.


Changes

.claude-plugin/setup.sh — detect OS and use the correct venv Python path:

if [[ "$(uname -s 2>/dev/null)" == MINGW* ]] || [[ "${OS:-}" == "Windows_NT" ]]; then
    VENV_PYTHON="${PLUGIN_ROOT}/.venv/Scripts/python.exe"
else
    VENV_PYTHON="${PLUGIN_ROOT}/.venv/bin/python"
fi

Also provides the correct uv install command per platform when uv is missing.

.mcp.json — replace hardcoded Python path with uv run, which handles venv activation cross-platform:

"command": "uv",
"args": ["run", "--directory", "${CLAUDE_PLUGIN_ROOT}", "--no-project", "python", "...run_server.py"]

.claude-plugin/marketplace.json — update source to the GitHub repo URL:

"source": "https://github.com/databricks-solutions/ai-dev-kit"

.claude-plugin/plugin.json — add hooks and mcp manifest fields, sync version to 1.1.0:

"hooks": "./hooks/hooks.json",
"mcp": "./.mcp.json"

Full Diff

diff --git a/.claude-plugin/marketplace.json b/.claude-plugin/marketplace.json
-      "source": "./",
+      "source": "https://github.com/databricks-solutions/ai-dev-kit",

diff --git a/.claude-plugin/plugin.json b/.claude-plugin/plugin.json
-  "version": "1.0.0",
+  "version": "1.1.0",
-  "skills": "./databricks-skills/"
+  "skills": "./databricks-skills/",
+  "hooks": "./hooks/hooks.json",
+  "mcp": "./.mcp.json"

diff --git a/.claude-plugin/setup.sh b/.claude-plugin/setup.sh
+# OS-agnostic Python path within the venv
+if [[ "$(uname -s 2>/dev/null)" == MINGW* ]] || [[ "$(uname -s 2>/dev/null)" == CYGWIN* ]] || [[ "${OS:-}" == "Windows_NT" ]]; then
+    VENV_PYTHON="${PLUGIN_ROOT}/.venv/Scripts/python.exe"
+else
+    VENV_PYTHON="${PLUGIN_ROOT}/.venv/bin/python"
+fi
+
-if [ -f "${PLUGIN_ROOT}/.venv/bin/python" ] && \
-   "${PLUGIN_ROOT}/.venv/bin/python" -c "import databricks_mcp_server" 2>/dev/null; then
+if [ -f "$VENV_PYTHON" ] && "$VENV_PYTHON" -c "import databricks_mcp_server" 2>/dev/null; then

-    echo "Install it with: curl -LsSf https://astral.sh/uv/install.sh | sh" >&2
+    if [[ "${OS:-}" == "Windows_NT" ]]; then
+        echo "Install it with: powershell -c \"irm https://astral.sh/uv/install.ps1 | iex\"" >&2
+    else
+        echo "Install it with: curl -LsSf https://astral.sh/uv/install.sh | sh" >&2
+    fi

-uv pip install --python .venv/bin/python -e "$TOOLS_CORE_DIR" --quiet >&2
-uv pip install --python .venv/bin/python -e "$MCP_SERVER_DIR" --quiet >&2
+uv pip install --python "$VENV_PYTHON" -e "$TOOLS_CORE_DIR" --quiet >&2
+uv pip install --python "$VENV_PYTHON" -e "$MCP_SERVER_DIR" --quiet >&2

-if .venv/bin/python -c "import databricks_mcp_server" 2>/dev/null; then
+if "$VENV_PYTHON" -c "import databricks_mcp_server" 2>/dev/null; then

diff --git a/.mcp.json b/.mcp.json
-      "command": "${CLAUDE_PLUGIN_ROOT}/.venv/bin/python",
-      "args": ["${CLAUDE_PLUGIN_ROOT}/databricks-mcp-server/run_server.py"],
+      "command": "uv",
+      "args": [
+        "run",
+        "--directory", "${CLAUDE_PLUGIN_ROOT}",
+        "--no-project",
+        "python",
+        "${CLAUDE_PLUGIN_ROOT}/databricks-mcp-server/run_server.py"
+      ],

Testing

Verified on Windows 11 with Git Bash:

  • setup.sh fresh install completes successfully
  • setup.sh re-run exits early (idempotency check passes)
  • uv run launches the MCP server correctly

No changes to macOS/Linux behavior — the OS detection falls through to the existing Unix paths.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions