Skip to main content

A fast dependency updater for Python and Node.js projects

Project description

upd logo

upd

A fast dependency updater for Python, Node.js, Rust, and Go projects, written in Rust.

Quick Start

# Run without installing (using uv)
uvx upd-cli

# Or with pipx
pipx run upd-cli

# Preview changes without modifying files
uvx upd-cli -n

Features

  • Multi-ecosystem: Python, Node.js, Rust, and Go dependencies
  • Fast: Parallel registry requests for all dependencies
  • Constraint-aware: Respects version constraints like >=2.0,<3
  • Smart caching: 24-hour version cache for faster subsequent runs
  • Update filters: Filter by --major, --minor, or --patch updates
  • Interactive mode: Approve updates individually with -i
  • Check mode: Exit with code 1 if updates available (for CI/pre-commit)
  • Major warnings: Highlights breaking changes with (MAJOR)
  • Format-preserving: Keeps formatting, comments, and structure
  • Pre-release aware: Updates pre-releases to newer pre-releases
  • Gitignore-aware: Respects .gitignore when discovering files

Installation

From crates.io

cargo install upd

# or with cargo-binstall (faster, pre-built binary)
cargo binstall upd

From PyPI

pip install upd-cli
# or with uv
uv pip install upd-cli

From source

git clone https://github.com/rvben/upd
cd upd
cargo install --path .

Usage

# Update all dependency files in current directory
upd

# Update specific files or directories
upd requirements.txt pyproject.toml

# Dry-run mode (preview changes without writing)
upd -n
upd --dry-run

# Verbose output
upd -v
upd --verbose

# Disable colored output
upd --no-color

# Disable caching (force fresh lookups)
upd --no-cache

# Filter by update type
upd --major      # Show only major (breaking) updates
upd --minor      # Show only minor updates
upd --patch      # Show only patch updates

# Combine filters
upd --major --minor  # Show major and minor updates only

# Interactive mode - approve updates one by one
upd -i
upd --interactive

# Filter by language/ecosystem
upd --lang python           # Update only Python dependencies
upd -l rust                 # Short form
upd --lang python --lang go # Update Python and Go only

# Version precision
upd --full-precision  # Output full versions (e.g., 3.1.5 instead of 3.1)

# Check mode - exit with code 1 if updates available (for CI/pre-commit)
upd --check
upd -c
upd --check --lang python  # Check only Python dependencies

Commands

# Show version
upd version

# Check for upd updates
upd self-update

# Clear version cache
upd clean-cache

Supported Files

Python

  • requirements.txt, requirements-dev.txt, requirements-*.txt
  • requirements.in, requirements-dev.in, requirements-*.in
  • dev-requirements.txt, *-requirements.txt, *_requirements.txt
  • pyproject.toml (PEP 621 and Poetry formats)

Node.js

  • package.json (dependencies and devDependencies)

Rust

  • Cargo.toml ([dependencies], [dev-dependencies], [build-dependencies])

Go

  • go.mod (require blocks)

Example Output

pyproject.toml:12: Would update requests 2.28.0 → 2.31.0
pyproject.toml:13: Would update flask 2.2.0 → 3.0.0 (MAJOR)
Cargo.toml:8: Would update serde 1.0.180 → 1.0.200
Cargo.toml:9: Would update tokio 1.28.0 → 1.35.0

Would update 4 package(s) in 2 file(s), 15 up to date

Output includes clickable file:line: locations (recognized by VS Code, iTerm2, and modern terminals).

Version Precision

By default, upd preserves version precision from the original file:

# Original file has 2-component versions
flask>=2.0        →  flask>=3.1        (not 3.1.5)
django>=4         →  django>=6         (not 6.0.0)

# Original file has 3-component versions
requests>=2.0.0   →  requests>=2.32.5

Use --full-precision to always output full semver versions:

upd --full-precision
flask>=2.0        →  flask>=3.1.5
django>=4         →  django>=6.0.0
requests>=2.0.0   →  requests>=2.32.5

Version Constraints

upd respects version constraints in your dependency files:

Constraint Behavior
>=2.0,<3 Updates within 2.x range only
^2.0.0 Updates within 2.x range (npm/Cargo)
~2.0.0 Updates within 2.0.x range (npm)
>=2.0 Updates to any version >= 2.0
==2.0.0 No updates (pinned)

Caching

Version lookups are cached for 24 hours in:

  • macOS: ~/Library/Caches/upd/versions.json
  • Linux: ~/.cache/upd/versions.json
  • Windows: %LOCALAPPDATA%\upd\versions.json

Use upd clean-cache to clear the cache, or upd --no-cache to bypass it.

Environment Variables

Variable Description
UV_INDEX_URL Custom PyPI index URL
PIP_INDEX_URL Custom PyPI index URL (fallback)
NPM_REGISTRY Custom npm registry URL
GOPROXY Custom Go module proxy URL
UPD_CACHE_DIR Custom cache directory

Development

# Build
make build

# Run tests
make test

# Lint
make lint

# Format
make fmt

# All checks
make check

License

MIT

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

upd_cli-0.0.7.tar.gz (74.9 kB view details)

Uploaded Source

Built Distributions

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

upd_cli-0.0.7-py3-none-win_amd64.whl (2.8 MB view details)

Uploaded Python 3Windows x86-64

upd_cli-0.0.7-py3-none-musllinux_1_2_x86_64.whl (2.8 MB view details)

Uploaded Python 3musllinux: musl 1.2+ x86-64

upd_cli-0.0.7-py3-none-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (2.8 MB view details)

Uploaded Python 3manylinux: glibc 2.17+ x86-64

upd_cli-0.0.7-py3-none-manylinux_2_17_aarch64.manylinux2014_aarch64.whl (2.6 MB view details)

Uploaded Python 3manylinux: glibc 2.17+ ARM64

upd_cli-0.0.7-py3-none-macosx_11_0_arm64.whl (2.5 MB view details)

Uploaded Python 3macOS 11.0+ ARM64

upd_cli-0.0.7-py3-none-macosx_10_12_x86_64.whl (2.7 MB view details)

Uploaded Python 3macOS 10.12+ x86-64

File details

Details for the file upd_cli-0.0.7.tar.gz.

File metadata

  • Download URL: upd_cli-0.0.7.tar.gz
  • Upload date:
  • Size: 74.9 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.12.12

File hashes

Hashes for upd_cli-0.0.7.tar.gz
Algorithm Hash digest
SHA256 0d66f4fcd1e0e9f5ba7df5ac3ba16fbb9812e6c1e440258243c788751e8906ef
MD5 7084dd63e23922ae02563275ee6bf6a4
BLAKE2b-256 26a850730d18727abd335bf25c2481f6ad7b833c9613d05a00e8855e00c6249a

See more details on using hashes here.

File details

Details for the file upd_cli-0.0.7-py3-none-win_amd64.whl.

File metadata

  • Download URL: upd_cli-0.0.7-py3-none-win_amd64.whl
  • Upload date:
  • Size: 2.8 MB
  • Tags: Python 3, Windows x86-64
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.12.12

File hashes

Hashes for upd_cli-0.0.7-py3-none-win_amd64.whl
Algorithm Hash digest
SHA256 785c6e873d185bfa60f15fe11678796422b9d4027ca3e43b858c0c093bd87676
MD5 a7133a4012d338603360f1600e77f512
BLAKE2b-256 8e643a09807033600e9c70c082171eff158ad5ce026b9f0f77586595cce150df

See more details on using hashes here.

File details

Details for the file upd_cli-0.0.7-py3-none-musllinux_1_2_x86_64.whl.

File metadata

File hashes

Hashes for upd_cli-0.0.7-py3-none-musllinux_1_2_x86_64.whl
Algorithm Hash digest
SHA256 ad2657709a4149cc40ab46fb95c8fbb3f91d952772ffbbad1c896ba4cf88b4db
MD5 a3e996d2e972da7fe3ab4ca0a958794b
BLAKE2b-256 a9fe30d638afdaa712201d1902907593ab8117fa2d0749c22ed844a67843bf8e

See more details on using hashes here.

File details

Details for the file upd_cli-0.0.7-py3-none-manylinux_2_17_x86_64.manylinux2014_x86_64.whl.

File metadata

File hashes

Hashes for upd_cli-0.0.7-py3-none-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Algorithm Hash digest
SHA256 5d22f589cb8b0020a85fc94e695afb2106996716133680ddb4009e4286716dc1
MD5 545d540c38adc7015cd8f4a8af984701
BLAKE2b-256 f235e1a13e8215fbe1f6938ce6c02d6d2befbf5a3e89888f281a909161660619

See more details on using hashes here.

File details

Details for the file upd_cli-0.0.7-py3-none-manylinux_2_17_aarch64.manylinux2014_aarch64.whl.

File metadata

File hashes

Hashes for upd_cli-0.0.7-py3-none-manylinux_2_17_aarch64.manylinux2014_aarch64.whl
Algorithm Hash digest
SHA256 4c30ddd3ca37611e86a0cd22bde419d8c861b3db6d941707385c2cbf729683f0
MD5 14f16f01eaa602f0f177b1118c5fb5a2
BLAKE2b-256 84a0b4e0ed2acdfe58fe10ac284eae6f51064362d38ae6c14787ee843ac97f39

See more details on using hashes here.

File details

Details for the file upd_cli-0.0.7-py3-none-macosx_11_0_arm64.whl.

File metadata

File hashes

Hashes for upd_cli-0.0.7-py3-none-macosx_11_0_arm64.whl
Algorithm Hash digest
SHA256 7d4d45fe3ada78981895ab9a4e94409b66a5adfac3799c63d732aef72ac978ba
MD5 9588d4019496e6873b1e7bd1129242fe
BLAKE2b-256 db4eb6677371ac94ae2b1ef561eeb11ae10869817f609475bcdf5c68b0924673

See more details on using hashes here.

File details

Details for the file upd_cli-0.0.7-py3-none-macosx_10_12_x86_64.whl.

File metadata

File hashes

Hashes for upd_cli-0.0.7-py3-none-macosx_10_12_x86_64.whl
Algorithm Hash digest
SHA256 2d28da227c42647577593795935e0b0cfb787edd7c4eff1e58c3b1e1f276ca67
MD5 8721539cad8371bbb52c838d2856481a
BLAKE2b-256 455cf64a10f1472257ceac40c8225f0d33c6726585a947a5c02cb49eb49cb51e

See more details on using hashes here.

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