Prevent Hazel running upon network drive connecting

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

Moderator: Mr_Noodle

I have a folder that I use to store images that need to be uploaded to a network drive, and I use Hazel to sync them. However, my local copies will sometimes get behind the ones on the server. This is fine normally—I have the rule set up so it only sends when I save the file. However, Hazel's rule will also sometimes send when the network drive connects, regardless of whether I've made changes, and this can cause undesired overwriting.

Is there a way to stop that?

My Hazel rule is:

If all of the following conditions are met:
- Extension is eps
- Name matches (rule)
- Date Last Match is before Date Last Modified

Do the following to the matched file or folder:
- Copy to folder [Network folder]
- Display notification with pattern Sent file to Network
futuraprime
 
Posts: 3
Joined: Mon Mar 06, 2017 10:07 am

Are you sure that when the drive connects that there aren't extant changes that need to be copied over?

If you want to minimize drive operations, consider using the sync action. This thread has more info on that: http://www.noodlesoft.com/forums/viewto ... 1593#p6500
Mr_Noodle
Site Admin
 
Posts: 11872
Joined: Sun Sep 03, 2006 1:30 am
Location: New York City

Generally not—the Hazel folder I'm running this on is in Dropbox; this usually means I've made and saved through changes on one computer, and then connected to the network drive from the other computer. Since the other computer's Hazel doesn't know the first computer has already processed the file, it sends it through again (sometimes a day later).
futuraprime
 
Posts: 3
Joined: Mon Mar 06, 2017 10:07 am

Do you have Hazel setup to process the same files from multiple machines? If so, then that's probably not a great idea as they will sometimes interfere with each other. I'd designate one machine to be the one that runs Hazel on those files.
Mr_Noodle
Site Admin
 
Posts: 11872
Joined: Sun Sep 03, 2006 1:30 am
Location: New York City

That'd be a sensible solution, but I've got no machine that's guaranteed to be powered on and connected to the network.

Perhaps the best way to resolve this would be to have Hazel write a text file into the same folder that tracks dates for when each file was last copied over (by either machine)?
futuraprime
 
Posts: 3
Joined: Mon Mar 06, 2017 10:07 am

Try the sync action. It only copies over minimal changes.
Mr_Noodle
Site Admin
 
Posts: 11872
Joined: Sun Sep 03, 2006 1:30 am
Location: New York City


Return to Support