Created
December 5, 2014 03:52
-
-
Save aj0strow/11f93c778b773f3ef69e to your computer and use it in GitHub Desktop.
Remove PDF Page
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
require 'combine_pdf' | |
input = 'filename.pdf' | |
output = 'filename.pdf' | |
num = 10 | |
pdf = CombinePDF.new | |
CombinePDF.new(input).pages.each.with_index(1) do |page, i| | |
pdf << page unless i == num | |
end | |
pdf.save output |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment