Skip to main content
Glama
tjws

disk-cleanup

by tjws
README.md
# mcp-disk-cleanup

本地磁盘清理扫描 MCP Server(stdio 传输,**零 API key、零联网、只读扫描**)。

让 Qoder / Qodo / Claude / Cursor 等支持 MCP 的客户端,直接帮你扫描磁盘、
找出大文件、重复文件、垃圾后缀、久未访问文件,生成可清理清单——**只列不删**。

## 提供的工具

| 工具 | 状态 | 说明 |
|---|---|---|
| `scan_large` | ✅ 可用 | 列出大于阈值的文件,按大小降序 |
| `scan_duplicates` | ✅ 可用 | 按内容 hash 找重复文件 |
| `scan_by_ext` | ✅ 可用 | 按后缀扫描(.tmp/.log/.cache…) |
| `scan_old` | ✅ 可用 | 扫描久未修改的文件 |
| `summarize` | ✅ 可用 | 目录体检:总大小/文件数/类型占比 |

## 本地接入(开发期)

在客户端的 `mcp.json` 加一项,指向本地 venv 解释器:

```json
{
  "mcpServers": {
    "disk-cleanup": {
      "command": "E:/pycharm/mcp-disk-cleanup/.venv/Scripts/python.exe",
      "args": ["E:/pycharm/mcp-disk-cleanup/server.py"]
    }
  }
}
```

## 发布后接入(PyPI / uvx)

```json
{
  "mcpServers": {
    "disk-cleanup": {
      "command": "uvx",
      "args": ["mcp-disk-cleanup"]
    }
  }
}
```

## 本地运行 / 调试

```bash
.venv/Scripts/python.exe server.py
# 或用官方 Inspector 可视化调试:
npx @modelcontextprotocol/inspector .venv/Scripts/python.exe server.py
```

## 安全

- 所有工具均为**只读**扫描,不删除、不移动、不修改任何文件。
- 删除动作默认不开放;如需清理,请基于扫描清单手动确认后操作。

TDQS

A3.6/5.0

Scored across 5 tools

Disambiguation5/5

Each tool targets a uniquely identifiable scan dimension: large files, duplicates, extension-based, old files, and summary. Even the four scan_* tools are clearly distinct by their filtering criteria, leaving no real ambiguity for an agent.

Naming Consistency4/5

The scan_* prefix creates a predictable pattern for the four scanning tools, and the criterion is clear in each name. summarize deviates from the prefix pattern but is still a sensible, readable action name rather than a random inconsistency.

Tool Count5/5

Five tools is well-scoped for a disk cleanup helper: the main scan dimensions are covered, and there is no redundant bloat. The set feels complete enough to be useful without overwhelming an agent.

Completeness2/5

The server can identify cleanup candidates but offers no cleanup action such as delete or move-to-trash, so an agent cannot complete an actual disk cleanup workflow. This is a significant functional gap given the server name and stated purpose.

Maintenance

ActivityMaintained
ResponsivenessNo issues