on 2013-06-28 17:57 Mike Beargie wrote
Can anyone assist me in finding the right way to pass this automator "app" a URL, and telling it to run in the background so it saves the PDF in the app-specified directory?
the page for the Automator Action you cite states that the work is done by a
command line app; if you look into the package for the action you'll find a
.scpt file, which is AppleScript code, and a url2pdf unix executable file;
reading through the .scpt you can see how the arguments for url2pdf are
constructed, so i would ignore Automator and just write a short, task-specific
calculated AppleScript to construct the shell command and call url2pdf
i moved url2pdf to /usr/local/bin and this worked as the calculation for a
Perform AppleScript step:
Let ([ $url_to_pass = "http://filemaker.com"; $posix_output_folder = "/tmp"; cmdstring = "/usr/local/bin/url2pdf --url=\"" & $url_to_pass & "\" --autosave-path=/tmp" ]; "do shell script " & Quote(cmdstring) )
Thank you very much Steve, we primarily do windows environments at work so I'm more familiar with the send event stuff than the apple command line / applescript stuff. Thanks for your well demonstrated example.
PS - If you'll be at devcon, let me buy you a round!