following the simple instructions in this answer: https://askubuntu.com/a/1048975 I installed pdftk as a snap on an ubuntu 18.04 VM. (we need some of the advanced features of pdftk on the command line like fill_forms ).
my problem: the command seems to be only half installed:
/some/path # pdftk
-> Usage:
pdftk <command>
Install, configure, refresh and remove snap packages. Snaps are
'universal' packages that work across many different Linux systems,
enabling secure distribution of the latest apps and utilities for
cloud, servers, desktops and the internet of things.
This is the CLI for snapd, a background service that takes care of
snaps on the system. Start with 'snap list' to see installed snaps.
Available commands:
< long list of snap commands >
so it seems to me as if 'pdftk' is registered as a tool in the bash, but if I try to use any of the usual pdftk commands, I get an error message like this:
pdftk forms/Form_FM.pdf fill_form /tmp/adsh/2017-4_1532602497.fdf output /some/path/2017-4_KF.pdf
-> error: unknown command forms/Form_FM.pdf, see 'snap help'
(this also happens with every other command I tried) so, how do I pass the commands and parameter to pdftk without snap trying to grab the parameter for itself?
edit: some diagnostics:
ls -l /usr/local/bin/pdftk
lrwxrwxrwx 1 root root 28 Jul 11 18:17 /usr/local/bin/pdftk -> /snap/bin/pdftk-smoser.pdftk
snap list pdftk
error: no matching snaps installed
snap list pdftk-smoser
Name Version Rev Tracking Developer Notes
pdftk-smoser 2.02-4 18 stable smoser -
hmmm...seems like I followed the older version of the answer, which had an additional step that symlinked /snap/bin/pdftk-smoser.pdftk to /usr/local/bin/pdftk