Skip to content
VS Code

bash command mcp for VS Code

io.github.mrorigo/bash-command-mcp

Sophisticated bash command MCP server that runs and manages shell execution.

client:VS Code transport:stdio runtime:npm

Install bash command mcp in VS Code

.vscode/mcp.json

{
  "inputs": [
    {
      "type": "promptString",
      "id": "otel-enabled",
      "description": "OTEL_ENABLED",
      "password": true
    },
    {
      "type": "promptString",
      "id": "otel-service-name",
      "description": "OTEL_SERVICE_NAME",
      "password": true
    },
    {
      "type": "promptString",
      "id": "otel-service-version",
      "description": "OTEL_SERVICE_VERSION",
      "password": true
    },
    {
      "type": "promptString",
      "id": "otel-exporter-otlp-endpoint",
      "description": "OTEL_EXPORTER_OTLP_ENDPOINT",
      "password": true
    },
    {
      "type": "promptString",
      "id": "otel-metric-export-interval-ms",
      "description": "OTEL_METRIC_EXPORT_INTERVAL_MS",
      "password": true
    },
    {
      "type": "promptString",
      "id": "bash-command-mcp-log-dir",
      "description": "BASH_COMMAND_MCP_LOG_DIR",
      "password": true
    }
  ],
  "servers": {
    "bash-command-mcp": {
      "type": "stdio",
      "command": "npx",
      "args": [
        "-y",
        "bash-command-mcp"
      ],
      "env": {
        "OTEL_ENABLED": "${input:otel-enabled}",
        "OTEL_SERVICE_NAME": "${input:otel-service-name}",
        "OTEL_SERVICE_VERSION": "${input:otel-service-version}",
        "OTEL_EXPORTER_OTLP_ENDPOINT": "${input:otel-exporter-otlp-endpoint}",
        "OTEL_METRIC_EXPORT_INTERVAL_MS": "${input:otel-metric-export-interval-ms}",
        "BASH_COMMAND_MCP_LOG_DIR": "${input:bash-command-mcp-log-dir}"
      }
    }
  }
}

VS Code prompts for each input the first time the server starts, so no secret is written to the file. VS Code docs

bash command mcp in other clients