File Organizer - project by Ankush Rana

AttainU
AttainU

FILE ORGANIZER.

My project is file organizer.By this project we can organize our files with different extensions into a respective folders and remove the mess created by the files of different extensions.For this I have firstly used os module from python library and imported it.

Then i have used path library module The Pathlib module in Python simplifies the way in working with files and folders.

It combines the best of Python's file system modules namely os, os.path, glob, etc.

Then i have created the dictionaries for Folders and extension Folders as KEYS and extensions as values for keys.

Then i have used file format for formatting the files according to their extensions and this will work in the cuurent directory only where the code is pasted 

or present.Then there is small program by which the files are organized and are moved to specified folder as specified according to the extensions,and makes 

the directory with the help of mkdir function used.Then for loop is used for checking that the directory is present or not and if it is present then then program 

continues otherwise the double directory gets deleted.this is all done in this org.py file,which is a basic program for designing file organizer.

Also the executable file of this program is made which is present with name org.exe i have created with the help of pyinstaller we need to install pyinstaller 

for this with help of a command pip install pyinstaller in the command prompt and then move to current directory where your org.py file is present and then 

type a command pyinstaller --onefile -w org.py and the execution file will be created in the folder named dist where this execution file will be stored ,now copy 

and paste this file where you want to organize the files and run this file it will automatically organize the files with different extensions to the specified folders.

This is all about File Organizer. 

 

ALSO I HAVE FOLLOWED THE PEP 8 STANDARDS YOU CAN CHECK MY CODE FOR IT.WITH THE HELP OF A LINK . http://pep8online.com/ 

PASTE MY CODE DIRECTLY INTO IT. I WAS NOT ABLE TO ADD MUCH COMMENTS IN THE CODE BECAUSE THIS PEP8 STANDARDS WERE NOT ALLOWING TO USE BIG COMMENTS SO SMALL COMMENTS 

ONLY HAVE BEEN ADDED AND ONLY IN THOSE PLACES WHERE I CAN ADD ACCORDING TO THIS PEP8 STANDARDS. REST I HAVE TRIED TO CUSTOMIZE THE CODE UPTO MUCH EXTENT.THANKS.

 

TECHNOLOGY USED:

PYTHON PROGRAMMING LANGUAGE. ALONG WITH THE EXECUTION FILE ATTACHED IN IT.

BY WHICH IT CAN BE RUNED DIRECTLY INT HE FOLDER WHERE YOU WANT TO ORGANIZE THE FILES.

 

DEMO: