I have 86 PDFs that I don't want to share on the internet and merge with online tools. I am using the PopOS Linux distro and I would like to merge it using the terminal.
PDF names are like 1.SubjectA
, 2. SubjectB
(start with Number. , so they are well ordered)
Here is what I found but none of them are merging in order:
qpdf --empty --pages *.pdf -- out.pdf
Example file names:
1. Why to learn System and Network.pdf
2. Network, Hardwares, LAN-WAN.pdf
3. Protocols-Ports, OSI-TCP IP.pdf
4. ARP, ICMP, RFC, IANA.pdf
...
Pattern is Number + .(dot) + space + name
qpdf --empty --pages "$@" -- out.pdf
and in your terninal type:printf -- "%s\0" ./*.pdf | sort -zV | xargs -0 ./script