home / skills / openclaw / skills / file-organizer
This skill automatically organizes files in a directory by moving them into subfolders based on extensions to keep folders tidy.
npx playbooks add skill openclaw/skills --skill file-organizerReview the files below or copy the command above to add this skill to your agents.
---
name: file_organizer
description: Automatically organize files in a specified directory by moving them into subfolders based on their file extensions. Use for cleaning up messy folders like Downloads or Desktop.
---
# File Organizer
Keep your directories tidy.
## Usage
Run `scripts/organize.ps1` with the target path.
Example: `powershell.exe -File scripts/organize.ps1 C:\Users\L\Downloads`
This skill automatically organizes files in a specified directory by moving them into subfolders based on file extensions. It is designed to quickly tidy messy folders like Downloads or Desktop and reduce manual file sorting. The implementation uses a simple script flow that is easy to run and adapt to your environment.
The script scans the target directory and groups files by extension. For each extension it creates a corresponding subfolder (for example, "pdf" or "jpg") and moves matching files into those folders. It skips directories and can be run on demand to re-organize a folder without altering file contents.
Which platforms does this script run on?
The provided script is a PowerShell script intended for Windows, but the organizing logic can be adapted to other platforms with a shell or Python implementation.
Will the script overwrite existing files?
The script moves files into extension-based folders and should avoid overwriting by preserving filenames; test on a sample folder to confirm behavior for duplicate names.