Skip to main content

A simple file sorter for all your folder

Project description

filesort

A simple Python script that automatically organizes files in a directory into folders based on their file types.
If a file type is not recognized, it will be placed in the others folder.

Features

  • Sorts files into categories such as application, images, documents, spreadsheets, presentation, audio, video, archives, code
  • Automatically creates the target folders if they don't exist
  • Puts unknown file types into an others folder
  • Cross-platform support (Linux, macOS, Windows)

Example

Before sorting: Alt text

After Sorting : Alt text

How to Install

How to Use

  • Open terminal in the directory you want to sort
  • Type filesort
  • directories (optional) use to determined wich directories you want the script to run. If empty will default into the current directory
  • flags (optional) use to determine wich directories you want to create. If empty will create all directories

Flags

flags determined wich directories will be created, you can combine multiple flags by typing filesort -flags.

  • -a create a directory for applications only
  • -i create a directory for images only
  • -d create a directory for documents only
  • -s create a directory for spreadsheets only
  • -p → create a directory for Presentations only
  • -au → create a directory for Audio files only
  • -v → create a directory for Videos only
  • -ar → create a directory for Archives / compressed files only
  • -c → create a directory for Code / source files only

You can combine multiple arguments for example:

filesort Downloads/ -a -c -d

Will sort files in the Downloads directories that match the directories created wich is applicaton, code, and documents

Supported File Types

  • Applications
    .exe, .msi, .bat, .cmd, .app, .dmg, .pkg, .bin, .run, .sh, .deb, .rpm, .jar, .apk, .xpi

  • Images
    .jpg, .jpeg, .png, .gif, .bmp, .tiff, .tif, .webp, .avif, .heif, .heic, .svg, .eps, .ai, .cr2, .cr3, .nef, .arw, .orf, .rw2, .dng

  • Documents
    .txt, .rtf, .odt, .md, .doc, .docx, .dot, .dotx, .pdf, .epub, .mobi, .azw3

  • Spreadsheets
    .xls, .xlsx, .xlsm, .xlsb, .xlt, .xltx, .xltm, .ods, .ots, .csv, .tsv, .numbers

  • Presentations
    .ppt, .pptx, .pptm, .pot, .potx, .potm, .odp, .otp, .key

  • Audio
    .mp3, .aac, .ogg, .wma, .m4a, .wav, .flac, .alac, .aiff, .aif, .opus, .amr, .mid, .midi

  • Video
    .mp4, .m4v, .mov, .avi, .wmv, .flv, .mkv, .webm, .ogv, .3gp, .3g2, .mts, .m2ts, .ts, .vob

  • Archives
    .zip, .rar, .7z, .tar, .gz, .bz2, .xz, .iso, .img, .dmg, .vhd, .vhdx, .tgz, .tbz2, .lz, .z

  • Code
    .html, .htm, .css, .js, .mjs, .cjs, .ts, .tsx, .php, .phtml, .rb, .aspx, .cshtml, .py, .pyw, .ipynb, .java, .c, .h, .cpp, .cc, .cxx, .hpp, .hxx, .cs, .go, .rs, .kt, .kts, .swift, .m, .mm, .sh, .bash, .ps1, .pl, .pm, .lua, .r, .R, .m, .jl, .sas, .yml, .yaml, .json, .xml, .toml, .ini, .md

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

catfile-0.1.0.tar.gz (4.6 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

catfile-0.1.0-py3-none-any.whl (4.8 kB view details)

Uploaded Python 3

File details

Details for the file catfile-0.1.0.tar.gz.

File metadata

  • Download URL: catfile-0.1.0.tar.gz
  • Upload date:
  • Size: 4.6 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.13.5

File hashes

Hashes for catfile-0.1.0.tar.gz
Algorithm Hash digest
SHA256 ed00945bed9fa74c6a828fff0ea93d80f525073b207160e8e4fbc22644a95a94
MD5 f887dda4b7f487153c0df019baf7e2ac
BLAKE2b-256 fabd42826912ecaceebbd28cc418e25499b015ac9d6ce0586c719d3e3f11e192

See more details on using hashes here.

File details

Details for the file catfile-0.1.0-py3-none-any.whl.

File metadata

  • Download URL: catfile-0.1.0-py3-none-any.whl
  • Upload date:
  • Size: 4.8 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.13.5

File hashes

Hashes for catfile-0.1.0-py3-none-any.whl
Algorithm Hash digest
SHA256 1d7bd6c00d4b11639a2b990b8ee383858a63c5f06ca7ab0bdbe91617c51965df
MD5 04eedf18ef4921c87e26662277dfef7d
BLAKE2b-256 e70cdfef5b4178f00faf4a16c47bc877bf5f7d1242927f66073628b0dc865fe5

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page