Organizing TV eps unarchiving/delete... almost there!

Get help. Get answers. Let others lend you a hand.

Moderator: Mr_Noodle

Hi there,

Here is my idea for using hazel

I have this directory setup

~/eps/tvshow1/season1/episode14/a.rar, a.r01, a.r02
~/eps/tvshow1/season2/episode15/x.rar, x.r01, x.r02

I want to do the following:

1) move my archives out of the the episode folder to its enclosing folder (ie. ~/eps/tvshow1/season1/episode14/a.rar to ~/eps/tvshow1/season1/a.rar)

2) unarchive in place

3) delete all other files

4) delete folders.

I believe I have 1 - 3 finished. here are my rules

1) Go into subfolders

If ALL of the following conditions are met for THE FILE OR FOLDER BEING MATCHED

KIND is FOLDER
then
Run rules on folder contents.

2) move archives

If ALL of the following conditions are met for THE FILE OR FOLDER BEING MATCHED

SUBFOLDER DEPTH is 3
KIND is archive
then
Move to folder ENCLOSING FOLDER

3) unarchive

If ALL of the following conditions are met for THE FILE OR FOLDER BEING MATCHED

SUBFOLDER DEPTH is 2
EXTENSION is rar
then
unarchive

4) delete all files left behind

If ALL of the following conditions are met for THE FILE OR FOLDER BEING MATCHED

SUBFOLDER DEPTH is GREATER THAN 2
then
MOVE to TRASH

5) delete empty folders (DOES NOT WORK :( )

If ALL of the following conditions are met for THE FILE OR FOLDER BEING MATCHED

KIND is FOLDER
Size is 0
then
MOVE to TRASH

I have no idea why the last one doesn't work eventhough that is exactly the same rules others have used...

Any helpful tips?
punchbuggy
 
Posts: 2
Joined: Mon Oct 01, 2012 10:41 pm

The rule ordering matters. In this case, the rule to go into subfolders matches first so the other ones don't get a chance to run. In general, you want more specific rules up top. Try reordering and use the preview to check your work.
Mr_Noodle
Site Admin
 
Posts: 11865
Joined: Sun Sep 03, 2006 1:30 am
Location: New York City

i have tried to re order and I still can't delete those empty folders.

Any suggestions?
punchbuggy
 
Posts: 2
Joined: Mon Oct 01, 2012 10:41 pm

Three suggestions.

(1) First, As Mr_Noodle suggested, what does the preview window say? Are these folders matching another rule, or are they not being matched at all? Check the window in order to debug.

(2) Try size < 1 byte

(3) Lastly, make sure that you're upgrading Hazel when an update is released. An earlier version of 3.0 had a bug in folder file size calculations (i.e. if you're still running that version, then this rule will fail)
a_freyer
 
Posts: 631
Joined: Tue Sep 30, 2008 9:21 am
Location: Colorado


Return to Support