Obsidian Cleaner
/install obsidian-cleaner
Obsidian Attachment Cleaner
A skill that automatically finds and moves loose images/attachments from your Obsidian vault root to the designated Attachments folder.
When to Use
Trigger when user says:
- "Clean Obsidian"
- "Clean attachments"
- "整理附件"
- "Move images to attachments"
- "Obsidian 清理"
Features
- Auto-discovery: Finds loose files (
.png,.jpg,.gif,.jpeg,.webp,.pdf,.docx) - Safe move: Moves files to
Attachments/folder (creates if not exists) - Dry run: Preview what will be moved before executing
- Detailed report: Shows exactly what was moved and where
Usage
Quick Clean (Auto-detect)
python obsidian_cleaner.py
Dry Run (Preview Only)
python obsidian_cleaner.py --dry-run
Specify Vault Path
python obsidian_cleaner.py --vault /path/to/Obsidian/Vault
Custom Attachments Folder
python obsidian_cleaner.py --attachments "My Attachments"
How It Works
- Scans Obsidian vault root for loose attachment files
- Checks if Attachments folder exists (creates if missing)
- Moves each file to the Attachments folder
- Reports what was moved and any errors
Configuration
Default vault path: ~/Documents/Obsidian Vault
Default attachments folder: Attachments/
Example Output
🔍 Scanning /Users/skin/Documents/Obsidian Vault for loose attachments...
📁 Found 3 files:
├── screenshot_20240101.png
├── photo.jpg
└── diagram.gif
📦 Moving to Attachments/...
✅ Success!
├── screenshot_20240101.png → Attachments/screenshot_20240101.png
├── photo.jpg → Attachments/photo.jpg
└── diagram.gif → Attachments/diagram.gif
🎉 3 files moved. Vault is now clean!
Integration
Add to your HEARTBEAT.md or daily routine:
## Daily Obsidian Cleanup (Optional)
If you notice loose images in your vault root, run:
- "Clean Obsidian" - Automatically organize attachments
Notes
- Only moves files, doesn't delete anything
- Won't overwrite existing files (skips with warning)
- Case-insensitive file extension matching
- Safe to run multiple times
- 确保已安装 OpenClaw(本地或 Docker 部署)
- 在对话框中输入安装命令:
/install obsidian-cleaner - 安装完成后,直接呼叫该 Skill 的名称或使用
/obsidian-cleaner触发 - 根据 Skill 的参数说明提供必要输入,即可获得结构化输出
Obsidian Cleaner 是什么?
Automatically clean up loose images and attachments in Obsidian vault root, moving them to the Attachments folder. Trigger when user says "clean obsidian", "clean attachments", or "整理附件". 它是一个面向 Claude Code / OpenClaw 的 AI Agent Skill 插件,目前累计下载 816 次。
如何安装 Obsidian Cleaner?
在 OpenClaw 或 Claude Code 对话框中运行命令「/install obsidian-cleaner」即可一键安装,无需额外配置。
Obsidian Cleaner 是免费的吗?
是的,Obsidian Cleaner 完全免费(开源免费),可自由下载、安装和使用。
Obsidian Cleaner 支持哪些平台?
Obsidian Cleaner 跨平台运行,可在任意部署了 OpenClaw / Claude Code 的环境中使用(cross-platform)。
谁开发了 Obsidian Cleaner?
由 sparkingskin-tech(@sparkingskin-tech)开发并维护,当前版本 v1.0.0。