Skip to main content

A collection of tools for working with PDF files

Project description

PDFGEARS

A collection of Python tools for working with PDF files.

Distributed on PyPI as pdfgears; the importable package is pdfgears.

Installation

pip install pdfgears

Features

  • rmbmk: Remove PDF bookmarks (outline entries) whose title consists only of Arabic numerals (e.g. "1", "2.", "10"), while preserving the links/destinations of the remaining bookmarks.

Usage

Command-line

# List all available commands
pdfgears-info

# Remove numeric-only bookmarks, overwriting the input (keeps a .bak backup)
rmbmk -i input.pdf

# Remove numeric-only bookmarks, writing to a new file
rmbmk -i input.pdf -o output.pdf

# Process every PDF matched by the shell glob
rmbmk -i *.pdf

Python API

from pdfgears import rmbmk

# Remove numeric-only bookmarks from a PDF
rmbmk.remove_numeric_bookmarks("input.pdf", output_path="output.pdf")

Notes

  • rmbmk automatically creates a .bak backup of the original file whenever it overwrites it in place (i.e. when -o/--output is omitted).
  • -o/--output can only be used with a single -i input file.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

pdfgears-0.1.0.tar.gz (5.3 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

pdfgears-0.1.0-py3-none-any.whl (6.7 kB view details)

Uploaded Python 3

File details

Details for the file pdfgears-0.1.0.tar.gz.

File metadata

  • Download URL: pdfgears-0.1.0.tar.gz
  • Upload date:
  • Size: 5.3 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.12

File hashes

Hashes for pdfgears-0.1.0.tar.gz
Algorithm Hash digest
SHA256 f91b13168bd9876e8bc5e9b40e596e68295a4af8d524a287b4e5a98f2b7ffe5a
MD5 451a0aa969ea3af3db3502db2088ec9d
BLAKE2b-256 a1c768028d748daa64d71337703c1d8079506167fa7ba7277551e8955f68d086

See more details on using hashes here.

Provenance

The following attestation bundles were made for pdfgears-0.1.0.tar.gz:

Publisher: publish.yml on AaronOET/pdftoolbox

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file pdfgears-0.1.0-py3-none-any.whl.

File metadata

  • Download URL: pdfgears-0.1.0-py3-none-any.whl
  • Upload date:
  • Size: 6.7 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.12

File hashes

Hashes for pdfgears-0.1.0-py3-none-any.whl
Algorithm Hash digest
SHA256 7b5a25565acbb4f07421ca612131ace18de0bfa3b407378ddffea03f6d290bdd
MD5 385bfdd2f125706a64f695d6a0a10846
BLAKE2b-256 c8c8c91fa905a209d33ecc33d1d5d147e7465753c07be0d76a1d2ee9fe8ef48e

See more details on using hashes here.

Provenance

The following attestation bundles were made for pdfgears-0.1.0-py3-none-any.whl:

Publisher: publish.yml on AaronOET/pdftoolbox

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page