Skip to content

ToshY/qpdf-docker

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

3 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

📃️ QPDF Docker

Current version Docker Hub

A dockerized version of QPDF.

Info

QPDF is a command-line tool and C++ library that performs content-preserving transformations on PDF files

🧰 Requirements

🐋 Usage

docker run -it --rm -v $(pwd)/files:/pdf t0shy/qpdf-docker:latest --help
Run "qpdf --help=topic" for help on a topic.
Run "qpdf --help=--option" for help on an option.
Run "qpdf --help=all" to see all available help.

Topics:
  add-attachment: attach (embed) files
  advanced-control: tweak qpdf's behavior
  attachments: work with embedded files
  completion: shell completion
  copy-attachments: copy attachments from another file
  encryption: create encrypted files
  exit-status: meanings of qpdf's exit codes
  general: general options
  help: information about qpdf
  inspection: inspect PDF files
  json: JSON output for PDF information
  modification: change parts of the PDF
  overlay-underlay: overlay/underlay pages from other files
  page-ranges: page range syntax
  page-selection: select pages from one or more files
  pdf-dates: PDF date format
  testing: options for testing or debugging
  transformation: make structural PDF changes
  usage: basic invocation

For detailed help, visit the qpdf manual: https://qpdf.readthedocs.io

Note: make sure to mount to the /pdf directory on the container.

Examples

Merge PDFs using wildcard character *.

docker run -it --rm -v $(pwd)/files:/pdf --entrypoint /bin/sh t0shy/qpdf-docker:latest -c 'qpdf --empty --pages *.pdf -- result.pdf'

Note: Entrypoint is changed to /bin/sh and supplying command with -c, as wildcard character * is interpreted by shell.

❕ License

This repository comes with a MIT license.