commandline equivalent of PDF export with preview I have several PNG images that I intend to include in a LaTeX document, but it does horrible things to non-vector images. I've been using preview to export the PNG as a PDF which remedies the problem.

I'd like to script this, so what would be the equivalent command in terminal to:


Open specified PNG file
Export as PDF to a file
Specify the page orientation (as it defaults to portrait which is rotating all my images 90˚


Pretty much any solutions considered, applescript, automator, shell etc.
This can be completed with the following Automator service workflow:



The Size Each Page to Fit option preserves the orientation of the original image(s) in my testing, so no rotation is required.