
PDF tooling for Go and the command line.
View the Project on GitHub pdfcpu/pdfcpu
Generally pdfcpu does not have to be configured.
There is a configuration directory for certificate and user font management and storing the default configuration in effect.
See Configuration Reset Required in v0.16
when upgrading an existing v0.15 or
older installation.
The generated file records a configuration schemaVersion, not the pdfcpu version. A release upgrade therefore
requires a reset only when its required configuration schema changes.
See Configuration Modes
for automatic, stateless and read-only access.
See Configuration Workflows
for common command sequences.
See Environment Variables
for configuration-root
precedence and platform defaults.
In automatic mode, a configuration-dependent command initializes this directory below the default user configuration directory when required.
Inspect the selected location without modifying it. The relevant path portion of the output is shown here; see config inspect for the complete text and JSON output contracts:
$ pdfcpu config inspect
mode: auto
source: os-default
...
config:
path: /Users/horstrutter/Library/Application Support/pdfcpu/config.yml
available: true
exists: true
writable: true
...
pdfcpu config list will also print the config file path followed by its content.
Please check out the config list command.
Certificates are needed for processing digital signatures.
pdfcpu keeps trusted certificates in the configuration directory below certs.
-tags pdfcpu_eutl initialize this store with an embedded snapshot of EU Trusted List certificate bundles.Use:
Certificates are located in the dir tree below certs:
$ tree
..
├── certs
│ ├── root-ca.pem
│ └── intermediate-ca.pem
├── config.yml
└── fonts
User fonts are installed using the fonts install command.
pdfcpu also stores internal representations of installed user fonts in the config dir.
$ tree
..
├── certs
├── config.yml
└── fonts
├── Roboto-Regular.gob
├── Unifont-JPMedium.gob
├── UnifontMedium.gob
└── UnifontUpperMedium.gob
Use the –conf
flag to select a custom configuration root. The configuration tree is
stored in the pdfcpu directory below that root.
Use --conf disable to select stateless mode. This is useful when the default
user configuration directory
is unavailable or the process must not access
filesystem configuration. Stateless mode cannot use user fonts or the trusted certificate store.
Read-only is not selected with a CLI flag. The CLI uses read-only loading internally for config inspect and
config validate; Go API applications may select it explicitly for externally provisioned configuration.