Skip to content

pdfscale

Resize a Letter size PDF file to A4 size using pdfscale.

  • First install Alpine Linux in WSL.
    • I had to enable virtualization in the BIOS/UEFI
    • F2 goes to BIOS on my Asus TUF
    • Go to Advanced mode, and change SVM to enabled
    • Also change UMA to auto, otherwise it won't boot!
  • Install bash (apk add bash)
  • Install pdfscale
  • Navigate to the folder (for example /mnt/h/ goes to H: drive)

pdfscale -r A4 -c full DPHL.pdf
Uses the -c switch to set the cropbox to full, otherwise PDF software shows wrong page sizes.

Process a whole folder:

for file in *.pdf; do [ -f "$file" ] && pdfscale -r A4 -c full "$file"; done