Skip to content

File Operations Prompts

🌐 Languages: English | Français

15+ ready-to-use prompts for file organization, renaming, and cleanup


Organize all files in ~/Cowork-Workspace/input/ by file type.
Create these folders:
- Documents (pdf, doc, docx, txt, md)
- Spreadsheets (xls, xlsx, csv)
- Images (jpg, jpeg, png, gif, svg)
- Archives (zip, tar, gz, rar)
- Other (everything else)
Move files to appropriate folders. Don't copy.
Create a summary in ~/Cowork-Workspace/output/organization-report.txt showing:
- Total files processed
- Files per category
- Any files that couldn't be categorized
Organize files in ~/Cowork-Workspace/input/ by date.
Create year/month folder structure:
- 2024/
- 01-January/
- 02-February/
- ...
- 2025/
- ...
Use file modification date for sorting.
Move files to appropriate folders.
Save summary to ~/Cowork-Workspace/output/date-organization.txt
Organize files in ~/Cowork-Workspace/input/ by project.
Analyze filenames and content to identify projects.
Create a folder for each project identified.
Put unclassifiable files in "Uncategorized/" folder.
Save a project index to ~/Cowork-Workspace/output/project-index.md with:
- Project name
- Number of files
- File types present
- Date range of files
Organize my downloaded files in ~/Cowork-Workspace/input/downloads/
Create structure:
- Applications/ (dmg, pkg, exe, app)
- Documents/ (pdf, doc, docx, txt)
- Images/ (jpg, png, gif, svg)
- Videos/ (mp4, mov, avi, mkv)
- Music/ (mp3, wav, flac, m4a)
- Archives/ (zip, rar, tar, gz)
- Code/ (js, py, html, css, json)
- Other/
Move files appropriately. Delete empty source folders after.
Report to ~/Cowork-Workspace/output/downloads-cleanup.txt

Rename files in ~/Cowork-Workspace/input/ to follow this pattern:
YYYY-MM-DD_descriptive-name.ext
Rules:
- Use file date for YYYY-MM-DD
- Convert spaces to hyphens
- Remove special characters
- Convert to lowercase
- Keep original extension
Create a rename log in ~/Cowork-Workspace/output/rename-log.csv with:
Original Name, New Name, Date
Add prefix "[PROJECT-X]_" to all files in ~/Cowork-Workspace/input/
Keep original filename after prefix.
Example: document.pdf β†’ [PROJECT-X]_document.pdf
Log changes to ~/Cowork-Workspace/output/prefix-log.txt
Rename files in ~/Cowork-Workspace/input/ with sequential numbers.
Pattern: 001_original-name.ext, 002_original-name.ext, etc.
Sort by: [file date / alphabetically / file size]
Start numbering at: 001
Save mapping to ~/Cowork-Workspace/output/number-mapping.csv
Remove date patterns from filenames in ~/Cowork-Workspace/input/
Patterns to remove:
- YYYY-MM-DD
- YYYYMMDD
- DD-MM-YYYY
- MM-DD-YYYY
Keep the rest of the filename intact.
Log changes to ~/Cowork-Workspace/output/date-removal-log.txt

Find duplicate files in ~/Cowork-Workspace/input/
Check for:
- Exact duplicates (same content)
- Similar filenames
- Same size files
DO NOT DELETE ANYTHING.
Create a report in ~/Cowork-Workspace/output/duplicates-report.md with:
- Groups of potential duplicates
- File sizes
- Locations
- Recommendation (which to keep)
Identify files older than [6 months / 1 year] in ~/Cowork-Workspace/input/
Create an archive folder: ~/Cowork-Workspace/input/archive-[date]/
Move old files there (don't delete).
Create manifest in ~/Cowork-Workspace/output/archive-manifest.txt with:
- Files archived
- Original locations
- File dates
- Total size archived
Find files larger than [100MB / 500MB / 1GB] in ~/Cowork-Workspace/input/
Create a report in ~/Cowork-Workspace/output/large-files.md with:
- File path
- Size
- Type
- Last modified date
Sort by size, largest first.
Include total size of all large files.
Find empty folders in ~/Cowork-Workspace/input/
List all empty folders found.
DO NOT DELETE without my confirmation.
Report to ~/Cowork-Workspace/output/empty-folders.txt with:
- Folder path
- Parent folder

Copy all [PDF / image / spreadsheet] files from ~/Cowork-Workspace/input/
to ~/Cowork-Workspace/output/extracted-[type]/
Include files in subfolders.
Maintain original subfolder structure in destination.
Create a list of extracted files in ~/Cowork-Workspace/output/extracted-files.txt
Find all files matching pattern "*[pattern]*" in ~/Cowork-Workspace/input/
Copy matching files to ~/Cowork-Workspace/output/matching-files/
Create a list with full paths in ~/Cowork-Workspace/output/pattern-matches.txt
Find all text files in ~/Cowork-Workspace/input/ containing "[search term]"
Create a report in ~/Cowork-Workspace/output/content-search.md with:
- File path
- Line numbers containing the term
- Context (line before and after)
Copy matching files to ~/Cowork-Workspace/output/matching-content/

Create this folder structure in ~/Cowork-Workspace/input/:
Projects/
β”œβ”€β”€ Active/
β”‚ β”œβ”€β”€ project-a/
β”‚ β”‚ β”œβ”€β”€ docs/
β”‚ β”‚ β”œβ”€β”€ assets/
β”‚ β”‚ └── deliverables/
β”‚ └── project-b/
β”‚ β”œβ”€β”€ docs/
β”‚ β”œβ”€β”€ assets/
β”‚ └── deliverables/
β”œβ”€β”€ Completed/
└── Templates/
Confirm structure created.
Create a complete inventory of ~/Cowork-Workspace/input/
Output to ~/Cowork-Workspace/output/inventory.xlsx with columns:
- Filename
- Path
- Extension
- Size (KB)
- Date Modified
- Type Category
Include summary sheet with:
- Total files
- Total size
- Files by type
- Files by year

From real-world usageβ€”complex sorting with explicit rules:

CONTEXT: My ~/Cowork-Workspace/input/downloads/ has 200+ files accumulated over months.
I need them organized for a project handoff.
TASK: Organize files following these rules in priority order:
RULES:
1. Client files (containing "ClientX" or "ProjectY") β†’ Clients/[ClientName]/
2. Financial (invoices, receipts, quotes) β†’ Finance/[Year]/
3. Design assets (.psd, .ai, .fig, .sketch) β†’ Design/
4. Documentation (.doc, .pdf, .md) β†’ Docs/[Topic]/
5. Code/scripts β†’ Code/
6. Everything else β†’ Archive/[Month-Year]/
OUTPUT:
- Move files according to rules
- Create ~/Cowork-Workspace/output/organization-manifest.xlsx with:
- Original path, New path, Rule applied, Date moved
- Summary counts per category
CONSTRAINTS:
- Process in batches of 20 files (for token efficiency)
- Ask confirmation before each batch
- Never delete, only move
- Report any ambiguous files for manual decision

File organization consumes tokens rapidly. Optimize with these patterns:

File CountApproachWhy
1-20Single requestFits easily
20-502-3 batched requestsOptimal efficiency
50-100Checkpoint every 20Recovery on failure
100+Sub-folder batchesPrevent context overflow
CONTEXT: ~/Cowork-Workspace/input/ contains 80+ files to organize.
TASK: Organize by type, but work efficiently:
APPROACH:
1. First: List all files and create a sorting plan (don't move yet)
2. Save plan to ~/Cowork-Workspace/output/sorting-plan.md
3. Wait for my approval
4. Then process in batches of 20 files
5. After each batch, report progress and wait for "continue"
CONSTRAINTS:
- Checkpoint progress after each batch
- If interrupted, the plan file shows what's done vs remaining
- Estimated total: 4-5 batches
CONTEXT: File organization was interrupted.
~/Cowork-Workspace/output/sorting-plan.md shows progress.
Files marked [DONE] are already processed.
TASK: Continue from where we stopped.
Process only items NOT marked [DONE] in the plan.
OUTPUT: Update sorting-plan.md as you process.
Mark completed items with [DONE].

Replace placeholders:

  • ~/Cowork-Workspace/input/ β†’ Your actual input folder
  • ~/Cowork-Workspace/output/ β†’ Your actual output folder
  • [brackets] β†’ Your specific values

Add constraints as needed:

  • β€œExclude hidden files”
  • β€œProcess only top-level, not subfolders”
  • β€œSkip files larger than X”
  • β€œOnly process files from last 30 days”

Token budget awareness:

  • Simple inventory: ~20K-30K tokens
  • Small organization (10-20 files): ~30K-50K tokens
  • Large organization (50+ files): ~80K-150K tokens
  • Pro tier: Plan for 1-2 large operations per 5-hour window

Back to Prompts Index | Cowork Documentation