pdfcpu

Logo

PDF tooling for Go and the command line.

View the Project on GitHub pdfcpu/pdfcpu


Changelog
Future Directions

Add Properties

This command adds property name/value pairs to a PDF document. Have a look at some examples.

You can also set the PDFs Title, Subject and Author.

Usage

pdfcpu properties add inFile nameValuePair... [flags]

Common Flags


Arguments

namedescriptionrequired
inFilePDF input file, use - to read from stdinyes
nameValuePair’name = value'yes

Examples

Adding a property:

$ pdfcpu properties add in.pdf name = value
$ pdfcpu properties add in.pdf 'name = value'

Adding two properties:

$ pdfcpu properties add in.pdf 'name1 = value1' 'name2 = value2'

Setting Title and Author:

$ pdfcpu properties add in.pdf 'Title = My title' 'Author = Me'

Add properties while reading and writing the PDF through pipes:

$ aws s3 cp s3://acme-assets/brochure.pdf - \
   | pdfcpu properties add - - 'Subject = Product Launch' \
   | aws s3 cp - s3://acme-assets/brochure-described.pdf