mcp-injector for VS Code

Configure VS Code natively to query mcp-injector and compress local context.

Why use mcp-injector with VS Code?

VS Code now natively supports the Model Context Protocol (MCP). Running mcp-injector alongside VS Code ensures your large codebase references are automatically compressed using AST folding, avoiding context bloat and maximizing response accuracy for your AI extensions.

1. Install the daemon

Download and run the setup script inside your project workspace:

curl -fsSL https://foldwork.dev/install | sh

If you run the installer from within a git repository, it will automatically configure .vscode/mcp.json for you.

2. Manual Configuration (Optional)

If you didn't run the installer in your project directory, you can configure VS Code manually by creating a .vscode/mcp.json file in your workspace:

{
  "servers": {
    "mcp-injector": {
      "command": "mcp-injector",
      "env": {
        "MCP_WORKSPACE": "${workspaceFolder}"
      }
    }
  }
}

3. Verification

Open your workspace folder in VS Code. Start a chat with your AI assistant and ensure the get_project_map and injector_retrieve tools are available and working.