Page 1 of 1

need help figuring out a rule for files in subfolders

PostPosted: Sun Jul 17, 2022 7:57 pm
by mrgreeneyes
hello,

i am trying to have hazel organize my downloads, and i am wondering if it is possible for hazel to do this:

scenario:
completed downloads
- Thor ( main folder)
- Subs (contains subtitles named english.srt)

what i want hazle to do is rename the subtitle to the name of the root folder it is in, is it possible?

Re: need help figuring out a rule for files in subfolders

PostPosted: Mon Jul 18, 2022 9:49 am
by Mr_Noodle
Is "Subs" under "Thor" or "completed downloads"? If under "Thor", look into nested conditions in the manual. You can set up something like:
Code: Select all
If (all) are met
    If (all) are met for (enclosing folder)
        If (all) are met for (enclosing folder)
            Name matches (• root folder name)

where (• root folder name) is set to match anything. This will store the folder name in that attribute which you can use as needed.

You will also need a separate rule to tell Hazel to go into subfolders. Again, check the manual.