Is there a way to run the same single action (i.e., eject FTP volume) following the conclusion of a "Run rules on folder contents" action?
I use Hazel to copy statements from an FTP folder provided by a broker to my Mac. The FTP folder has date-based subfolders, one for each business day, each subfolder holding multiple statements, one each for several accounts. I link the following rules to the FTP top folder:
1. Apply rules to subfolders: for kind is folder, Run rules on folder contents
2. Copy statements: based on selection criteria, copy certain PDFs from FTP folder to a folder on my Mac.
This process works without a hitch. Except, about 15-25 minutes following the conclusion of Hazel processing, my Mac crashes. I've determined the crash is related to the FTP connection, but I've been unable to solve it. So, I avoid the problem by manually ejecting the FTP immediately following the Hazel processing. But this requires monitoring the Console and manually ejecting the FTP volume. This is tedious and error prone.
How can I have Hazel automatically eject the FTP following the copy process? The actual eject is simply running AppleScript: tell application "Finder" activate eject "mylogin@myftp.com" end tell. But I can't figure out the conditions to trigger this action.
Ideas?