Copy file and mark the original with color label

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

Moderator: Mr_Noodle

Hi,

my general problem is that I have a ruleset that copies a file rule after rule to different servers (AFP or SMB mounted).
Now a file in that folder needs to be copied to several ones based on a check for different namings. At the end of the ruleset I have a rule that moves all files to a final destination. I need "Continue matching rules" because files maybe need to be copied to different servers depending how they are named.
So I want to be sure that the files got copied to the servers before they get moved to a final destination.

Here my problems start:
I copy to a share that I sometimes loose connection. Hazel tries to copy and fails but says:

2017-05-26 11:48:40.665 hazelworker[5590] Processing folder TXT_Werbeaussage (forced)
2017-05-26 11:48:48.839 hazelworker[5590] a=00000_AT_TEST_WAGA.txt: Rule Remove color label "EMPTY" matched.
2017-05-26 11:48:48.903 hazelworker[5590] a=00000_AT_TEST_WAGA.txt: Rule COPY to Komponentenimport LFS008 "Werbeaussage 2" matched.
2017-05-26 11:48:49.954 hazelworker[5590] [Error] Could not sync file/folder: Could not sync file/folder at a=00000_AT_TEST_WAGA.txt to /Volumes/L-FS65/LFS/Test/Transferserver/storage/TXT_Werbeaussage_Aktion_Komponente/Werbeaussage2/a=00000_AT_TEST_WAGA.txt.
2017-05-26 11:48:49.954 hazelworker[5590] Sync returned error status: 23

Probably it does not find the mount/path or anything else goes wrong. It does happen just sometimes.
Now the rule "COPY to Komponentenimport LFS008 "Werbeaussage 2" matched and because of "Continue matching rules" it goes on with the rulesetting and finally moves the file to the final destination.

However I tried to implement color labels to check if a copy was really done. Is getting set on the copied file and not on the original. How can I ensure to just label the original AFTER the copy?
Numork
 
Posts: 7
Joined: Thu Mar 24, 2011 8:42 am

If you use the Copy action, subsequent actions always apply to the copy. You can try using the Sync action instead. Actions after that one apply to the original.
Mr_Noodle
Site Admin
 
Posts: 11872
Joined: Sun Sep 03, 2006 1:30 am
Location: New York City

Hi,

thanks a lot! I have tested sync and it works in general with color marking. But I have a sync folder that is on a server (windows) and so I get alsways Error 23 when the sync should happen. I tested a snyc on a folder on my desktop and it works. I even got rid of color labeling for the sync on the share but it does not work. Is it because it is a windows server? Are there any other restrictions (mounts such as smb, cfis or server configurations needed?)

Well my basic issue is still to ensure that a copy to a destination has happened. Are there any other solutions?

Thanks in advance!
Numork
 
Posts: 7
Joined: Thu Mar 24, 2011 8:42 am

I'm guessing that the Windows server does not support certain metadata that exists on the Mac side. As a result, the sync will fail. Alternatively, you can try using a script to do the copy since actions that occur after scripts operate on the original file (unless you tell it to do otherwise).
Mr_Noodle
Site Admin
 
Posts: 11872
Joined: Sun Sep 03, 2006 1:30 am
Location: New York City


Return to Support