Page 1 of 1

Embedded Script Running on Wrong File

PostPosted: Sun Oct 07, 2012 11:53 pm
by ptoomey3
Hey,
I am relatively new to Hazel, but I am having an issue with running an embedded script. Again, I am new, but I would have sworn that this used to work the way I thought it would, but now I am having issues. I have a rule that monitors a folder for images. When a new image is found I do the following:

Run an embedded script: chmod 777 "$1" (it is a long story...but it is needed for what I am doing)
Do a "Copy to Folder" action on the file that was chmod(ed) above
Run an embedded script to delete the original file: rm "$1"

It seems that the second embedded script is actually acting on the copied file and not the origional file that was found in the monitored folder. Is that expected behavior?

Re: Embedded Script Running on Wrong File

PostPosted: Mon Oct 08, 2012 11:18 am
by Mr_Noodle
Yes. Actions after a copy action work on the copy. Why not do a move operation?