Skip to content

Latest commit

Β 

History

9 Commits

Folders and files

NameName
Last commit message
Last commit date
Β 
Β 
Β 
Β 
Β 
Β 

Repository files navigation

🧹 Clean My Downloads

A Python script to automatically organize and clean your Downloads folder by:

  • Sorting files into folders based on type (Images, Documents, Videos, etc.)
  • Removing .exe files (optional cleanup of installers)
  • Detecting and removing duplicate files by comparing their contents
  • Logging every action for transparency

πŸ“‚ How It Works

This script scans your ~/Downloads folder and:

  1. Deletes any .exe files to free up space
  2. Sorts files into type-based folders in your home directory:
    • Images/
    • Documents/
    • Videos/
    • Music/
    • Archives/
    • Others/ (for uncategorized files)
  3. Finds duplicate files (with identical content) and keeps only the latest version

πŸš€ Features

  • βœ… Automatically organizes by file type
  • πŸ—‘οΈ Deletes .exe files safely
  • πŸ” Finds duplicates using full file comparison (filecmp)
  • 🧠 Keeps your newest file version
  • πŸ“ Logs actions with timestamps using Python's logging module

πŸ“¦ Requirements

  • Python 3.6 or newer
  • Works on macOS, Linux, and Windows
  • No external libraries required (uses only the Python standard library)

▢️ Usage

  1. Clone this repository:
git clone https://github.com/ApparentlyTejas/ProjectsInPython.git
cd ProjectsInPython
python cleanDownloader.py
🧠 Customization
You can change the behavior by editing the script:

File types β†’ Modify the file_type_folders dictionary in main()

Number of duplicates β†’ Currently deletes all but the newest

Safety β†’ You could add a dry-run mode or confirmation prompts


## πŸ™‹β€β™‚οΈ Author
Tejas Malhotra
Automation enthusiast.
Follow me or contribute at github.com/ApparentlyTejas

About

No description, website, or topics provided.

Resources

Stars

6 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages