
File Manager
OpenClaw自动化文件管理助手,用于批量文件操作、智能分类、重复文件清理、文件重命名、目录同步等任务。当用户需要整理文件、批量重命名、清理重复文件、同步目录或自动化文件工作流时使用此技能。
The three checks behind Skill health
What our agents found
Efficient skill76/100
- NoteDescription doesn't say when to use it (no trigger wording).
- NoteDoesn't say when NOT to use it, so it may switch on at the wrong time.
- NoteShort (271 words): may leave the agent guessing.
Safe to install100/100
- PassNo red-flag patterns found.
Legally cleared100/100
- PassOpen licence: MIT-0.
Checked by our agents (auto-1) on November 18, 2026. They read the file; they don't run it.
Before you install
Read the skill's files before you install. Our agents read the file but never run it, and popularity at a source is not a security review.
Read the full SKILL.md271 words
name: file-manager description: OpenClaw自动化文件管理助手,用于批量文件操作、智能分类、重复文件清理、文件重命名、目录同步等任务。当用户需要整理文件、批量重命名、清理重复文件、同步目录或自动化文件工作流时使用此技能。
File Manager - OpenClaw 自动化文件管理
核心功能
1. 智能文件分类 (organize)
按文件类型、日期、大小或自定义规则自动分类文件。
# 按文件类型分类
python scripts/organize.py <source_dir> --by-type
# 按日期分类 (年/月/日)
python scripts/organize.py <source_dir> --by-date --date-format year/month
# 按文件大小分类 (尚未实现)
# python scripts/organize.py <source_dir> --by-size --size-ranges "10MB,100MB,1GB"
2. 批量重命名 (batch_rename)
支持正则表达式、序列号、日期等模式的重命名。
# 添加前缀/后缀
python scripts/batch_rename.py <pattern> --prefix "IMG_" --suffix "_2024"
# 使用正则替换
python scripts/batch_rename.py "*.jpg" --replace "IMG_(\d+)" "Photo_\1"
# 序列号重命名
python scripts/batch_rename.py "*.jpg" --sequence --padding 4
3. 重复文件清理 (deduplicate)
基于内容哈希检测并处理重复文件。
# 扫描并列出重复文件
python scripts/deduplicate.py <directory> --scan-only
# 删除重复文件(保留最旧/最新)
python scripts/deduplicate.py <directory> --keep oldest --action delete
# 移动重复文件到隔离目录
python scripts/deduplicate.py <directory> --action move --to <quarantine_dir>
4. 目录同步 (sync)
双向或单向目录同步,支持排除模式和增量同步。
# 单向同步 (源 → 目标)
python scripts/sync.py <source> <target> --mirror
# 双向同步 (尚未实现)
python scripts/sync.py <dir1> <dir2> --bidirectional
# 排除特定文件
python scripts/sync.py <source> <target> --exclude "*.tmp,*.log,.git"
使用模式
常见场景
场景1: 整理下载文件夹
# 自动分类下载的文件
python scripts/organize.py ~/Downloads --by-type --move
场景2: 清理重复照片
# 扫描重复照片
python scripts/deduplicate.py ~/Pictures --scan-only
场景3: 批量整理项目文件
# 按日期整理项目文件
python scripts/organize.py ./projects --by-date --date-format year/month
场景4: 自动备份工作目录
# 同步到备份目录,排除临时文件
python scripts/sync.py ~/Work ~/Backups/Work --exclude "node_modules,.git,*.tmp"
工作流
文件整理工作流
- 分析目录结构和文件分布
- 选择分类策略 (类型/日期/大小/自定义)
- 执行整理 (dry-run 预览 → 确认 → 执行)
- 验证结果
清理工作流
- 扫描重复/过期/大文件
- 生成报告并预览
- 用户确认或自动处理
- 移动到回收站/隔离区/直接删除
同步工作流
- 分析源和目标差异
- 预览待同步的文件列表
- 确认后执行同步
- 显示同步统计
安全原则
- 预览优先: 所有修改操作默认执行 dry-run 预览,需加 --execute 才执行
- 操作确认: 执行前需要用户输入 yes 确认
- 符号链接安全: 遍历目录时跳过符号链接,避免无限递归
- 冲突保护: 目标文件已存在时自动重命名或跳过,不会覆盖
⚙️ 依赖安装与环境初始化
环境要求
- Python 3.8+
- 无外部依赖,仅使用 Python 标准库
脚本参数说明
直接查看脚本帮助获取详细参数:
python scripts/<script>.py --help
Shown as published by the author under MIT-0 · original. Skills are instructions your agent follows: read them before you install. Provided as-is, no warranty.

Challenge our agents' review
Skill health comes from our agents' three checks. Think one of them got it wrong? Pick the check, say whether the score should go up or down, and show your evidence. A reviewer checks it: if it holds up, the score changes and you earn points.

Crowd reviews
Used this skill? Give it stars and say what worked. Ratings from signed-in people make Crowd Love; they never change Skill health.
- No reviews yet. Be the first.