Python File Backup & Organizer

Customer: AI | Published: 26.01.2026

I’m looking for a clean, well-documented Python solution that keeps my file system in order and, above all, automates incremental backups. The script should watch one or more “source” directories, detect everything that has changed since the last run, and copy only the new or modified files to a versioned backup location. While it works, I also want it to tidy up what it finds: • Sort new or unsorted files into sub-folders based on type or an existing folder structure. • Detect duplicates with a content hash rather than name alone, then move those duplicates into a clearly named “_duplicates” folder so nothing is lost. • Log every action—sorting decisions, hash results, backup statistics—into a dated log file for easy review. Key expectations • Incremental backup logic that is reliable even across system restarts. • Cross-platform compatibility (Windows & Linux) with no obscure dependencies—standard Python 3.x plus well-known libraries like pathlib, hashlib, shutil, logging, maybe watchdog if you prefer real-time triggers. • Safe operations: no destructive moves, no silent overwrites. • A simple configuration file or CLI flags so I can point the script at new folders, change retention rules, or turn features on/off without touching the code. • Clear README and inline comments so I can extend it later. Acceptance criteria 1. Run the script twice in a row: the second pass must detect no changes and finish quickly. 2. Drop a duplicate file into the source: it should appear once in the backup and once in the “_duplicates” folder with an identical hash confirmed in the log. 3. Delete nothing unless I explicitly pass a “–purge” flag; otherwise, all operations are copy or move only. Deliverables • Well-structured Python source code. • Configuration template (e.g., YAML/JSON or argparse flags). • Sample log demonstrating one full pass plus one incremental pass. • Brief README with setup and usage instructions. If you’ve built similar tooling or have ideas to make the workflow even smoother, let me know. I value reliability and clarity over fancy UIs, so the focus should stay on rock-solid, test-covered Python code.