I searched for a possibility to create a pdf with exactly the edited image files (no explicit page format, for example). And this is what I finally used… it can serve as an example for more use cases by changing the jq
and/or convert
parameters:
paperwork-json show 20220202_1125_25 | jq '.pages[].image' | convert @- ~/tmp/x.pdf
Explanation of the command line
-
paperwork-json
: export document info as json -
jq
: generate a list of image files for this document in the correct order -
convert
read file list from stdin (using@-
) and output as pdf