Releases: warshipfucker/pdfsplitter
Releases · warshipfucker/pdfsplitter
Release main
pdfsplitter
This Python script allows you to split a large PDF file into smaller PDF files. You can specify the input PDF file, the prefix for the output files, and the number of pages per small file.
Usage Windows
- Download release - Exe File
- Put the big pdf file (the file you want to split) to same folder with pdfsplitter.exe file
- Run pdfsplitter.exe
- Follow the on-screen instructions to split your PDF file:
- Enter the name of the large PDF file (with or without .pdf ending).
- Enter the prefix for the output files.
- Enter the number of pages per small file.
- The script will create a folder with the same name as the input PDF file (without the .pdf extension) and save the smaller PDF files there.
- The process is completed, and you will find the splited PDF files in the specified folder.
Requirements
- Python 3.x
- PyPDF2 library (you can install it using
pip install PyPDF2
)
Usage of source code
- Download and install Python from the official website.
- Open a terminal or command prompt.
- Clone or download this repository to your computer.
- Navigate to the directory where the script is located.
- To install the required PyPDF2 library, open a terminal or command prompt, navigate to the directory with the script, and run the following command:
pip install -r requirements.txt
orpip install PyPDF2
- Run the script using the following command:
python3 pdfsplitter.py
orpython pdfsplitter.py
- Follow the on-screen instructions to split your PDF file:
- Enter the name of the large PDF file (with or without .pdf ending).
- Enter the prefix for the output files.
- Enter the number of pages per small file.
- The script will create a folder with the same name as the input PDF file (without the .pdf extension) and save the smaller PDF files there.
- The process is completed, and you will find the split PDF files in the specified folder.
Example
Suppose you have a large PDF file named example.pdf
, and you want to split it into smaller files with a prefix of output
and 10 pages per small file. You would run the script as follows:
Enter the following when prompted:
- Enter the name of the large PDF file:
example.pdf
- Enter the prefix for the output files:
output
- Enter the number of pages per small file:
10
The script will create a folder named example
and save the split PDF files inside.
License
This project is licensed under the Apache License 2.0 - see the LICENSE file for details.