In the present day I have been establishing a brand new Folder Motion automator workflow for pdf to picture conversion (that is truly the primary time I am working with script and automation in any respect, so there could also be rudimentary errors). The workflow works as meant: after I drop in a pdf picture into the designated watch folder, the file will get transformed right into a png and prompts me to put it aside to a different path. However there’s one constant downside that I am unable to resolve.
The folder I exploit because the “Folder Motion Folder” (folder title in Finder “Automated Conversion”) is underneath one other folder — name it the “Isolation Folder” (folder title in Finder “Grapher Export”) — which is underneath the person’s Photos folder (like under).
Photos -> Isolation Folder -> Folder Motion Folder (the folder designated within the Folder Motion workflow)
This is a screenshot of my folder construction in Finder, hope it helps a bit:
I did this in order that the “Folder Motion” folder is remoted from every day actions and I will not be by chance including any recordsdata to it. However I found that placing recordsdata within the “Isolation Folder”, regardless of it being the mum or dad folder of the “Folder Motion Folder”, nonetheless triggers the automator workflow. I’m very confused that it labored like that.
Photos -> Isolation Folder (placing file right here triggers workflow, bizarre) -> Folder Motion Folder
I did some experiments for this. In a single, I added a subfolder to the “Folder Motion Folder”, after which added a file to that subfolder. This triggered the workflow as nicely.
Photos -> Isolation Folder -> Folder Motion Folder -> New Folder (placing file right here additionally triggers workflow)
However including recordsdata to the mum or dad folder of the “Isolation Folder”, which is the Photos folder, does not set off any of that.
Photos (placing file right here doesn’t set off workflow) -> Isolation Folder -> Folder Motion Folder
I attempted re-creating that workflow, re-creating the folders, restarting my Mac, however the scenario remained the identical. Should not Folder Motion workflow be solely working for that one folder designated solely, with out getting influenced by any actions in its mum or dad or sub folder? Does anybody have any concept on what is going on right here? How ought to I make it that solely including recordsdata to the designated “Folder Motion Folder” will set off the workflow?
My macOS model is Sequoia 15.6.1, and here is a screenshot of my workflow:
The AppleScript I used (I mixed the code from https://www.macscripter.web/t/save-files-to-a-user-chosen-location-at-runtime/71181 and Google’s search AI):
on run {enter, parameters}
-- Specify the textual content file to retailer the trail.
set pathFile to (alias "Macintosh HD:Customers:andyzou:Photos:Grapher Export:" as textual content) & ".last_folder.txt"
-- Learn the final saved path from the file, if it exists.
attempt
set lastPath to (learn file pathFile as textual content)
on error
-- If the file doesn't exist, set the default path to the Desktop.
set lastPath to path to desktop as alias
finish attempt
set destinationFolder to (select folder with immediate "Select a vacation spot folder for the Grapher Export" default location lastPath)
-- Get the POSIX path of the chosen folder.
set theChosenPath to POSIX path of destinationFolder
-- Write the brand new path to the textual content file for subsequent time.
set fileRef to open for entry file pathFile with write permission
set eof of fileRef to 0
write theChosenPath to fileRef
shut entry fileRef
inform software "Finder"
transfer enter to destinationFolder with changing
finish inform
inform software "Finder"
delete (each merchandise of folder ("Macintosh HD:Customers:andyzou:Photos:Grapher Export:Automated Conversion:"))
finish inform
return enter
finish run


