pdfmerge

Command-line utility for merging, splicing, and rotating PDF documents.

https://github.com/metaist/pdfmerge

Science Score: 13.0%

This score indicates how likely this project is to be science-related based on various indicators:

  • CITATION.cff file
  • codemeta.json file
    Found codemeta.json file
  • .zenodo.json file
  • DOI references
  • Academic publication links
  • Committers with academic emails
  • Institutional organization owner
  • JOSS paper metadata
  • Scientific vocabulary similarity
    Low similarity (14.3%) to scientific vocabulary

Keywords

pdf python
Last synced: 6 months ago · JSON representation

Repository

Command-line utility for merging, splicing, and rotating PDF documents.

Basic Info
Statistics
  • Stars: 140
  • Watchers: 6
  • Forks: 26
  • Open Issues: 4
  • Releases: 4
Topics
pdf python
Created about 13 years ago · Last pushed about 2 years ago
Metadata Files
Readme Changelog Contributing Funding License

README.md

pdfmerge: CLI for merging, splicing, and rotating PDFs

pdfmerge
Staple the Squirrel

Build PyPI Supported Python Versions

Why?

I find myself merging bits of different PDFs fairly regularly and really wanted a simple CLI way to do it.

Install

bash python -m pip install pdfmerge

Usage

$ pdfmerge [-h] [--version]
  [-o FILE|--output FILE]
  [-p PASSWORD|--password PASSWORD]
  PATH[RULE[, RULE ...]] [[PATH[RULE, ...]] ...]
  • -o, --output output file (default: output.pdf).
  • -p, '--password` password for encrypted files (default: empty string).
  • PATH a file, directory, or wildcard string (e.g., file*.pdf) of files to merge.
  • RULE an optional string indicating which pages to extract and rotate. The syntax for each rule is:

    [START][..][END][ROTATE]

Where START and END are positive (1-based) or negative page numbers and ROTATE is one of >, V, or < indicating a clockwise rotation of 90, 180, 270 degrees, respectively.

Command-line Example

$ pdfmerge -o out.pdf file1.pdf file2.pdf[3,3] file2.pdf[1V,2..-1] "other*.pdf[<]" "/path/pdf[1..4>,5]"

This example illustrates several features:

  • specifying an output file
  • merging multiple files, some more than once
  • splicing parts of file using indices (1-based; negatives allowed)
  • including the same page multiple times
  • rotating a page or page range
  • merging all the PDFs in a directory

Read more about the options

Python Module Usage

pdfmerge can also be imported into python scripts.

python from pdfmerge import pdfmerge pdfmerge(["pdf-1.pdf", "pdf-2.pdf[2>]"], "output.pdf")

License

MIT License

Owner

  • Login: metaist
  • Kind: user

GitHub Events

Total
  • Issues event: 2
  • Watch event: 15
  • Fork event: 2
Last Year
  • Issues event: 2
  • Watch event: 15
  • Fork event: 2

Committers

Last synced: over 2 years ago

All Time
  • Total Commits: 57
  • Total Committers: 5
  • Avg Commits per committer: 11.4
  • Development Distribution Score (DDS): 0.088
Past Year
  • Commits: 13
  • Committers: 2
  • Avg Commits per committer: 6.5
  • Development Distribution Score (DDS): 0.154
Top Committers
Name Email Commits
The Metaist m****t@m****m 52
Y.D.X 7****7 2
maethu b****i@g****h 1
Lukas Bindreiter l****r@o****m 1
Akash Rajendra a****a@g****m 1
Committer Domains (Top 20 + Academic)

Issues and Pull Requests

Last synced: 7 months ago

All Time
  • Total issues: 28
  • Total pull requests: 6
  • Average time to close issues: 7 months
  • Average time to close pull requests: about 1 year
  • Total issue authors: 12
  • Total pull request authors: 6
  • Average comments per issue: 1.46
  • Average comments per pull request: 2.5
  • Merged pull requests: 4
  • Bot issues: 0
  • Bot pull requests: 0
Past Year
  • Issues: 4
  • Pull requests: 0
  • Average time to close issues: 1 day
  • Average time to close pull requests: N/A
  • Issue authors: 3
  • Pull request authors: 0
  • Average comments per issue: 2.0
  • Average comments per pull request: 0
  • Merged pull requests: 0
  • Bot issues: 0
  • Bot pull requests: 0
Top Authors
Issue Authors
  • metaist (15)
  • marmadmax (1)
  • ismailuddin (1)
  • rolandnsharp (1)
  • no1xsyzy (1)
  • dcanl (1)
  • voostar (1)
  • patricktokeeffe (1)
  • YDX-2147483647 (1)
  • Xsmael (1)
  • betesh (1)
  • mbeffa (1)
Pull Request Authors
  • begert (1)
  • arjndr (1)
  • lukasbindreiter (1)
  • YDX-2147483647 (1)
  • thisirs (1)
  • shreyas (1)
Top Labels
Issue Labels
enhancement (5) bug (4) wontfix (1) question (1)
Pull Request Labels

Packages

  • Total packages: 1
  • Total downloads:
    • pypi 535 last-month
  • Total docker downloads: 63
  • Total dependent packages: 0
  • Total dependent repositories: 4
  • Total versions: 8
  • Total maintainers: 1
pypi.org: pdfmerge

Command-line utility for merging, splicing, and rotating PDF documents.

  • Versions: 8
  • Dependent Packages: 0
  • Dependent Repositories: 4
  • Downloads: 535 Last month
  • Docker Downloads: 63
Rankings
Docker downloads count: 3.0%
Stargazers count: 7.1%
Average: 7.3%
Dependent repos count: 7.5%
Downloads: 7.9%
Forks count: 8.0%
Dependent packages count: 10.0%
Maintainers (1)
Last synced: 6 months ago

Dependencies

requirements.txt pypi
  • PyPDF2 >=1.21
  • coverage >=3.6
  • nose >=1.2.1
  • pep8 >=1.4.4
  • pylint >=1.2.1