Created
October 9, 2021 20:52
-
-
Save sergiolucero/5e5e01cbc86e056f2e5f425ca9384995 to your computer and use it in GitHub Desktop.
how to merge PDF files
This file contains 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
import glob | |
from PyPDF2 import PdfFileMerger | |
merger = PdfFileMerger() | |
for fn in glob.glob('*.pdf'): | |
merger.append(fn) | |
merger.write('merged.pdf') | |
merger.close() |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment