I want to pipe pdf-generating output through pdftk to remove annotations.
How can I combine this existing portion of a working AppleScript line:
do shell script "/usr/local/bin/$pdf-generating-app --page-size=A4 --page-margin=5mm " & (quoted form of POSIX path of filename) & " -o " & (quoted form of POSIX path of outputFilename)
And have that piped through pdftk to remove annotations, as per this script by Farid Cheraghi?
sh pdftk in.pdf output - uncompress | sed '/^\/Annots/d' | pdftk - output out.pdf compress