Made a working .py mvp (used a bit of stack overflow for hashing, like what the heck is sha256) nex I am gonna make a cli I am imaging it like thos bash toolboxes only mine just cleans up your files.Basically how it works is:
- Each file gets a distinct hashing value based on its content and is storred in a list (seen_hashes)
- If 2 files have the same hash value (same content) the file is saved once in the duplicates folder (check happens comparing with the seen_hashes)
- We have a dictionary called cattegories with various extentions and which cattegory they fall in so the file is compared to the extantions with a for loop that if looped thru without finding and storing in the right cattegory is saved in misc.
- Every file not oppened or touched for 30 days is discarded upon check / scan
- A file handler class makes the process easier utilising basic oop concepts
I am off to adding codes file cuz I found out all my codes went to misc!
Comments 0
No comments yet. Be the first!
Sign in to join the conversation.