This is a file automation script that automatically organizes downloaded files into categorized folders (e.g., Videos, Images, Documents, etc.). It uses Python's watchdog library to monitor the Downloads folder and move files accordingly.
- ✅ Real-time Monitoring: Automatically detects new files.
- 📂 Auto-Organization: Moves files into respective folders.
- 📝 Customizable File Categories: Supports Images, Videos, Documents, Code, Archives, etc.
- 🛠 Error Handling & Logging: Tracks errors in a log file.
- 🧪 Unit Tests: Includes test cases to verify file movement.
git clone https://github.com/DanielXDev/File-Automation.git
cd File-Automationpython -m venv venv
# Activate (Windows)
venv\Scripts\activate
# Activate (Mac/Linux)
source venv/bin/activatepip install -r requirements.txtModify config.json to set your Download folder path and file categories.
python main.pyFile Automation
│── logs/ # Stores log files
│── venv/ # Virtual environment (not included in GitHub)
│── config.json # Configuration file
│── main.py # Main script
│── requirements.txt # Dependencies
│── test_file_automation.py # Unit tests
To run unit tests:
python -m unittest discover tests- Python
watchdog(file monitoring)shutil(file operations)logging(error handling)unittest(testing)
MIT License.
- 📌 GUI interface for easier configuration.
- 📊 Dashboard to track moved files.
- 🌐 Cloud integration for backups.
Feel free to submit pull requests or report issues!
⭐ Star this repo if you find it useful! ⭐