Skip to content

smithery-ai/shell-mcp

 
 

Repository files navigation

shell-mcp

Shell command execution MCP server

Version License

An MCP server implementation that provides secure shell command execution capabilities for LLMs.

Features

  • Secure Execution: Whitelisted commands and arguments only
  • Resource Control: Memory and CPU usage monitoring
  • Timeout Control: Automatic termination of long-running commands
  • Size Limits: Output size restrictions for safety
  • MCP Integration: Works with Claude and other MCP-compatible LLMs

Installation

npm install @kevinwatt/shell-mcp

Configuration with Dive Desktop

  1. Click "+ Add MCP Server" in Dive Desktop
  2. Copy and paste this configuration:
{
  "mcpServers": {
    "shell": {
      "command": "npx",
      "args": [
        "-y",
        "@kevinwatt/shell-mcp"
      ]
    }
  }
}

Tool Documentation

  • execute_command
    • Execute whitelisted shell commands
    • Inputs:
      • command (string, required): Command to execute
      • args (array, optional): Command arguments
      • timeout (number, optional): Execution timeout in ms

Usage Examples

Ask your LLM to:

"Show current directory: pwd"
"List files: ls -l"
"Check disk usage: df -h"

Manual Start

If needed, start the server manually:

npx @kevinwatt/shell-mcp

Requirements

  • Node.js 18+
  • MCP-compatible LLM service

Development

# Install dependencies
npm install

# Watch mode
npm run watch

# Run tests
npm test

# Lint
npm run lint

License

MIT © Kevin Watt

Keywords

  • mcp
  • shell
  • command
  • claude
  • llm
  • automation

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • TypeScript 75.6%
  • JavaScript 24.4%