BenV's notes

Splitting up a PDF file

by on Sep.30, 2010, under Boring

If you have colleagues like mine you’ll eventually find an email in your inbox that’s about 20MB because of some PDF file attached to it. Apparently it’s some manual of a device that we work on, but I only care about 5 pages out of the 400-ish pages in the pdf.

Here’s a neat trick to split it into a new PDF file by using ghostscript.
This makes a new PDF file with pages 300-305:

benv@yourmom:/tmp> gs -dBATCH -dNOPAUSE -q -sDEVICE=pdfwrite -dFirstPage=300 -dLastPage=305 -dOUTPUTFILE=yournewpdf.pdf SomeHugeInput.pdf

Thanks for the hint guys at cs.cmu.edu 🙂

And all that without the Adobe Cancer.
PS. A while ago I discussed The Adobe Cancer. Obviously google instantly put my notes as the #1 result when you searched for Adobe and Cancer. I liked that.
However, a few days later that search somehow didn’t hit my notes anymore. Weird huh.
Thus, I must repeat it: Adobe CANCER. Especially that Adobe Acrobat is Cancer. Let’s not forget the update checkers, Adobe Update Manager or Adobe Download Manager … Adobe CANCER Manager. Feh.




:, , , ,

Leave a Reply

You must be logged in to post a comment.

Archives

  • 2018 (1)
  • 2016 (1)
  • 2015 (7)
  • 2014 (4)
  • 2013 (11)
  • 2012 (27)
  • 2011 (26)
  • 2010 (25)
  • 2009 (68)