On this page
Convert ODT to PDF
Contrary to the previous items of the toolchain that rely exclusively on One-Pager Chords Python scripts, PDF generation is actually based on fairly standard tools.
Tip
A One-Pager Chords toolchain utility bash script can take care of running all the commands in that section:
bash [toolchain/pdf_export.sh](toolchain/pdf_export.sh) odt_dir pdf_dirPDF generation
libreoffice --headless --convert-to pdf sample.odtTip
A LibreOffice bug currently prevents batch generation of PDF files for more than ~250 files. To workaround this issue, run the following commands:
libreoffice --headless &
sleep 2
libreoffice --headless --convert-to pdf sample.odtTagging PDF with Artist and Title
This step relies on exiftool tag operations. The -csv option allows to batch import tags from a CSV file into multiple files.
A One-Pager Chords toolchain utility bash script can take care of it all:
bash [toolchain/pdf_tag.sh](toolchain/pdf_tag.sh) sample.pdfCompression of PDF files
qpdf sample.pdf --object-streams=generate --linearize output.pdfMerging of PDF files
To merge multiple PDF files into one compressed PDF file, you can use:
qpdf --empty \
--pages sample1.pdf \
sample2.pdf \
sample3.pdf -- \
--object-streams=generate --linearize output.pdf