Generic MCP Configuration

Configure Glider with any MCP-compatible client.

Verify the active worktree

Use a project-local config: Claude Code .mcp.json, Codex .codex/config.toml (trusted projects), Cursor .cursor/mcp.json, or VS Code .vscode/mcp.json. Include portable config files in version control, or copy local config files into each worktree. Git does not copy ignored files. Use absolute paths only when you intentionally want one fixed checkout, such as a global Claude Desktop configuration.

Open the client at the selected worktree root. Relative server arguments use the server launch directory, not the config file directory. Project scope alone does not guarantee that directory. If the client starts elsewhere, configure its MCP working directory or use a Git-root launcher.

Run git rev-parse --show-toplevel in the client terminal, then ask server_status for the server workspace. Confirm that the loaded solution or workspace belongs to that worktree before you query or change code. For a wrong root, explicitly load the intended workspace or restart the server with the correct path.

An existing HTTP server keeps its own workspace when the client changes directories. Use separate servers and ports for simultaneous worktrees.

git rev-parse --show-toplevel

Prerequisite

Prerequisite: .NET 10 SDK must be installed before running dotnet tool install --global glider.

Recommendation: Project/Workspace Scope

When possible, configure Glider per project/workspace. This avoids launching it for unrelated projects. Most clients read a project-scoped config file: Claude Code .mcp.json (claude mcp add --scope project), Cursor .cursor/mcp.json, VS Code / GitHub Copilot .vscode/mcp.json, Gemini CLI .gemini/settings.json, OpenCode opencode.json, and Pi .mcp.json. Claude Desktop only supports one global claude_desktop_config.json with no per-project scope, so pin a project there by adding --solution to its args, or use Claude Code for per-project setups.

Agent system prompt instruction

Add this product-specific instruction to your MCP client system prompt or project instructions after connecting Glider.

When working in C#/.NET workspaces, prefer glider mcp semantic tools for symbol identity, code relationships, diagnostics, dependencies, impact analysis, and preview-first refactors. Use Scout for repository retrieval and raw text questions. Use the .NET CLI for build and test commands. Preload the solution with --solution, or call load before semantic queries.

macOS / Windows / Linux: ensure glider is on PATH

Most clients can run glider directly if your .NET tools directory is on PATH.

# bash/zsh
export PATH="$PATH:$HOME/.dotnet/tools"
which glider

Stdio Transport (common: mcpServers JSON)

Many clients (Cursor, Gemini CLI, Pi, etc.) use this format. Replace the file location with your client’s recommended project/workspace config file.

{
  "mcpServers": {
    "glider": {
      "command": "glider",
      "args": ["--default-timeout", "30m"]
    }
  }
}

VS Code / Copilot (mcp.json)

VS Code uses a different config format (see VS Code docs: code.visualstudio.com/docs/copilot/customization/mcp-servers).

{
  "servers": {
    "glider": {
      "type": "stdio",
      "command": "glider",
      "args": ["--default-timeout", "30m"]
    }
  }
}

HTTP Transport

If your client requires HTTP, start Glider in HTTP mode and point the client at http://localhost:5001/mcp. This example raises the async-tool timeout to 30 minutes; --default-timeout also accepts values like 45s or 0:

# Start Glider in HTTP mode
glider --transport http --default-timeout 30m

# Then configure your client to connect to:
# http://localhost:5001/mcp

HTTP Transport (common: mcpServers JSON)

For clients that accept a URL in mcpServers, use this shape after starting Glider in HTTP mode.

{
  "mcpServers": {
    "glider": {
      "url": "http://localhost:5001/mcp"
    }
  }
}

HTTP Transport (VS Code / Copilot)

For VS Code and GitHub Copilot Chat, use type: "http" and the same local endpoint.

{
  "servers": {
    "glider": {
      "type": "http",
      "url": "http://localhost:5001/mcp"
    }
  }
}

Environment Variables

# Custom port and timeout for HTTP transport
glider --transport http --port 8080 --default-timeout 30m

Preload your project at startup (recommended)

Add --solution <path> to the launch arguments in the configuration above so Glider loads your solution or project (a .sln, .slnx, or .csproj file) at startup, instead of waiting for the agent to call load. With it set, server_status shows the workspace as loaded — or, on a large workspace, still loading in the background under workspaceLoading — from the first message, so the agent can wait for that load to finish instead of stopping with a "No solution loaded. Use load first." message and reaching for text search. Put the flag after -- for claude mcp add, add it to the args array in JSON and Codex TOML configs, or to the single command array for OpenCode. For worktrees, prefer a relative path and launch the server from the selected worktree root. Relative paths use the server launch directory, not the config file directory. An absolute path intentionally pins one checkout.

# From the selected worktree root; replace src/App.slnx with your solution path.
glider --solution src/App.slnx --default-timeout 30m
# Add --workspace <dir> to watch a different root, or --no-watch to disable file watching.
↑/↓ NavigateEnter OpenSpace Expand