Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- def extractDatBitch(wootdir):
- WhereShitsGoing = "D:\PlexWatchFolder"
- for path, dicks, stuff in os.walk(wootdir):
- for EachFile in stuff:
- filepath = os.path.join(path, stuff)
- if rarfile.is_rarfile(filepath):
- print("I think I got one... %s") % filepath
- try:
- print("Maybe... maybe...") % filepath
- with rarfile.RarFile(filepath) as rf:
- rf.extractall(path=WhereShitsGoing)
- except:
- print("Well %s was an archive, it's probably a multipart and you can only exract that first one.") % filepath
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement