Skip to content

Instantly share code, notes, and snippets.

@exussum12
Created July 3, 2018 20:46
Show Gist options
  • Save exussum12/b966eb92d06889a0fe211791d8422a2c to your computer and use it in GitHub Desktop.
Save exussum12/b966eb92d06889a0fe211791d8422a2c to your computer and use it in GitHub Desktop.
FlippingBook to PDF
#!/bin/bash
mkdir -p out
for i in $(seq 1 120); do
page=`printf "%04d" $i`;
wget "https://www.website/files/assets/common/page-html5-substrates/page${page}_4.jpg"
wget "https://www.website/files/assets/common/page-vectorlayers/${page}.svg"
convert -flatten -geometry 1149x2550 -fuzz 10% -transparent white -density 400 page${page}_4.jpg $page.svg out/$page.pdf
done;
cd out
pdfunite * out.pdf
@shayanb
Copy link

shayanb commented May 4, 2020

Any chance to got around this?

@devorel
Copy link

devorel commented Feb 3, 2022

it's font error . try install it .

@K-RAD
Copy link

K-RAD commented Jun 6, 2025

I got this to work, but the resulting pdf pages are missing some letters here and there. Any idea why that happens?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment