pdfshot
A Python CLI to export pages from PDF files as images.
Quickstart
- Install poppler (macOS):
brew install poppler.
Usage:
$ pdfshot [OPTIONS] INPUT_PATH PDF_PAGE
Arguments:
INPUT_PATH: The input PDF file. [required]PDF_PAGE: The page number of the PDF file to export as an image. Page numbering starts at 1 (1-based indexing). [required]
Options:
-b, --add-border: Add border to the page image. [default: False]--version: Show the version and exit.--install-completion: Install completion for the current shell.--show-completion: Show completion for the current shell, to copy it or customize the installation.--help: Show this message and exit.
Notes
- pdf2image:
- To only convert PDF files to images.
- Commands:
poetry init+poetry install.poetry add "typer[all]".which pdfshot.pdfshot test.pdf 1orpdfshot test.pdf 1 --add-border.
- Typer:
- CLI arguments (required by default): CLI parameters (
./myproject, for example) passed in some specific order to the CLI application (ls, for example). - CLI options (optional by default): CLI parameters (
--size, for example) passed to the CLI application with a specific name. - Data validation.
- Numeric validation.
- For commands, think of
git(git push,git clone, etc.).
- CLI arguments (required by default): CLI parameters (
- Poetry:
- Outdated metadata after version bump for local package (open) issue.
References
Metadata
Release files for pdfshot 0.2.1
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| pdfshot-0.2.1.tar.gz | 4.6 kB | Without provenance | Details for pdfshot-0.2.1.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| pdfshot-0.2.1-py3-none-any.whl | Python 3 | none | any | Details for pdfshot-0.2.1-py3-none-any.whl |
Total release size: 9.8 kB
Release files / pdfshot-0.2.1.tar.gz
| Download URL | pdfshot-0.2.1.tar.gz |
|---|---|
| Size | 4.6 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
9688c31f312423d6a85e8b5ac93585d14f16d35f14a2ff7eddb915e90a3abcf9
|
|
BLAKE2b-256 checksum How to use checksums |
3c80845cbb2ed8b493016968630bfadacbfe6c1279c7cb54118b857688df4e90
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
poetry/1.1.4 CPython/3.6.13 Linux/5.4.0-1046-azure
|
Release files / pdfshot-0.2.1-py3-none-any.whl
| Download URL | pdfshot-0.2.1-py3-none-any.whl |
|---|---|
| Size | 5.2 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
39950f8ea24cef4a8ce272ce1240956dba933f048fe7eea6a87269fba204a1eb
|
|
BLAKE2b-256 checksum How to use checksums |
53377f1110e53d3ee8bc81f8cffa9b5f10c973a6e2cc60ebafc15f116de3b735
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
poetry/1.1.4 CPython/3.6.13 Linux/5.4.0-1046-azure
|
Security for pdfshot 0.2.1
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.