Page 1 of 1

Run a rule on subfolder (of a monitored folder)

PostPosted: Thu May 27, 2021 3:22 am
by andy4222
Hi everyone, new to hazel and did some research here and at other places but couldn't resolve my problem.

My hazel rule is monitoring a folder (named dropbox) hierarchy as follows
Code: Select all
- dropbox
    - backups
         - alfred_pref
             - alfred_pref.preferences


I want to create a rule that backups this file every 7 days. But the rule copies the parent folder (backups with its other subfolders) when it's triggered. I only want to copy the alfred_pref folder in this case. I also don't want to monitor the alfred_pref folder separately. Want to keep monitored folders to the min. Any help?

Rule:
Code: Select all
- if all conditions are met
    - name is alfred_pref
    - date last matched not in last 7 days
DO
- copy to downloads folder

Re: Run a rule on subfolder (of a monitored folder)

PostPosted: Thu May 27, 2021 10:43 am
by Mr_Noodle
You'll need to tell Hazel to go into subfolders via a separate rule. Check the manual as there is a chapter dedicated to this topic.