Skip to main content

Resizy

PyPI Python License: MIT CLI: Typer Terminal UI: Rich

Resizy is a fast, production-minded CLI for batch image resizing, conversion, and compression. It keeps the terminal responsive with ProcessPoolExecutor, validates images before processing, and gives every run a polished Rich progress UI.

Resizy terminal demo

Resizy summary

Why Developers Like It

  • Resize, convert, and compress hundreds of images from one command.
  • Keep your shell readable with Rich progress bars, panels, and summaries.
  • Avoid heavyweight services. No Docker, Redis, Celery, or background daemon.
  • Install globally with pipx, isolated from your app dependencies.
  • Preview batch plans with --dry-run before writing files.
  • Gracefully handles corrupted files, invalid formats, and partial failures.

Install

pipx is recommended because it installs Resizy as a global terminal command while keeping its dependencies isolated from your projects.

If you already have pipx:

pipx install resizy

If pipx is not installed yet:

python -m pip install --user pipx
python -m pipx ensurepath

Close and reopen your terminal, then run:

pipx install resizy

On Windows, if python is not available but the Python launcher is:

py -m pip install --user pipx
py -m pipx ensurepath
pipx install resizy

Before Resizy is published to PyPI, install it locally from the repository:

git clone https://github.com/mwlyra/resizy.git
cd resizy
pipx install .

For local development:

pip install -e ".[dev]"

Run the test suite:

pytest

Usage

Convert the demo images to compact WebP files:

resizy run ./examples/images --format webp --width 1000 --quality 82 --output ./examples/output

Preview a batch before writing anything:

resizy run ./images --format webp --width 1000 --dry-run

Convert JPEG and PNG assets to WebP with smart compression:

resizy run ./images --format webp --quality 82

Process nested folders with more workers:

resizy run ./assets --recursive --workers 8 --format webp --width 1920

Write outputs to a specific directory:

resizy run ./campaign --output ./dist/images --width 1200 --quality 76

Resize a single file:

resizy run ./hero.png --format jpeg --width 2400 --quality 88

Delete originals after successful processing:

resizy run ./raw --format webp --cleanup-originals

CLI Options

resizy run --help

Common flags:

  • --width, --height: Resize while preserving aspect ratio.
  • --format: Convert to jpeg, png, webp, bmp, or tiff.
  • --quality: Compression quality from 1 to 100.
  • --workers: Number of background worker processes.
  • --recursive: Scan directories recursively.
  • --output: Choose the output directory.
  • --dry-run: Preview matched files and planned outputs without writing files.
  • --overwrite: Replace existing output files.
  • --preserve-metadata: Preserve EXIF metadata when supported.
  • --cleanup-originals: Remove source files after successful processing.

Architecture

Resizy is intentionally small and scalable:

  • cli.py owns command parsing and terminal presentation.
  • processor.py owns validation, image operations, and process-pool orchestration.
  • config.py centralizes supported formats, defaults, and package settings.

The main process stays responsive while CPU-bound image work runs in isolated worker processes. Results are streamed back as each file completes, so users get real-time feedback instead of a frozen terminal.

Supported Inputs

Resizy accepts JPEG, PNG, WebP, GIF, BMP, and TIFF images. Each file is opened and verified with Pillow before processing so corrupted or unsupported files fail gracefully in the summary table.

License

MIT

Metadata

Release files for resizy 0.2.0

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for resizy 0.2.0
File Size Uploaded Provenance Actions
resizy-0.2.0.tar.gz 10.6 MB Without provenance Details for resizy-0.2.0.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for resizy 0.2.0
File Interpreter ABI Platform Actions
resizy-0.2.0-py3-none-any.whl Python 3 none any Details for resizy-0.2.0-py3-none-any.whl

Total release size: 10.6 MB

Release files / resizy-0.2.0.tar.gz

Download URL resizy-0.2.0.tar.gz
Size 10.6 MB
Tags Source
SHA-256 checksum
How to use checksums
245df00c9f290bba631437556490f88060fb0ec3aecd218cc7bcd37a1b412ee6
BLAKE2b-256 checksum
How to use checksums
2c0e2740ba216d0c692407edbd561dabb066194a1760bfc0a0963a4e7e5a9889
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.2.0 CPython/3.14.3

Release files / resizy-0.2.0-py3-none-any.whl

Download URL resizy-0.2.0-py3-none-any.whl
Size 11.3 kB
Tags Python 3
SHA-256 checksum
How to use checksums
89e03f26167e721eab55f1e6268020b0197e31f94780927e7482ce190af8dd76
BLAKE2b-256 checksum
How to use checksums
147a08dd42351b6b3599a6d7181a5ffccffc15d681bd423a55fdd249e08a7b08
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.2.0 CPython/3.14.3

Security for resizy 0.2.0

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.

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page