Skip to main content

Update dependencies and optional dependencies in pyproject.toml files.

Project description

Unit tests PyPI - Python Version Libraries.io dependency status for GitHub repo

Update dependencies and optional dependencies in pyproject.toml files.

Getting Started

Install and run:

pip install uppd
uppd --help

usage: uppd [-h]
            [-i INFILE]
            [-o OUTFILE]
            [-m [{<,<=,==,>=,>,~=} ...]]
            [--skip [SKIP ...]]
            [--dev [DEV ...]]
            [--pre [PRE ...]]
            [--post [POST ...]]
            [--index-url INDEX_URL]
            [--log-level {DEBUG,INFO,WARNING,ERROR,CRITICAL}]
            [--log-file LOG_FILE]
            [--dry-run]
            [-v]

Update Python Project Dependencies.

options:
-h, --help            show this help message and exit
-i INFILE, --infile INFILE
                      path(s) to input file(s) (default: pyproject.toml)
-o OUTFILE, --outfile OUTFILE
                        path(s) to output file(s). (default: [])
-m [{<,<=,==,>=,>,~=} ...], --match-operators [{<,<=,==,>=,>,~=} ...]
                      operators to upgrade. (default: ['==', '<=', '~='])
--skip [SKIP ...]     dependencies to skip upgrade. (default: [])
--dev [DEV ...]       dependencies to upgrade to dev release. (default: [])
--pre [PRE ...]       dependencies to upgrade to pre release. (default: [])
--post [POST ...]     dependencies to upgrade to post release. (default: ['*'])
--index-url INDEX_URL
                      base URL of the Python Package Index. (default: https://pypi.org)
--log-level {DEBUG,INFO,WARNING,ERROR,CRITICAL}
                      logging level. (default: INFO)
--log-file LOG_FILE   pipe loggining to file instead of stdout. (default: None)
--dry-run             do not save changes to output file(s). (default: False)
-v, --version         show program's version number and exit

Usage

Set inputs and output files:

uppd -i dev/pyproject.toml
uppd -i pyproject.toml -o pyproject.toml.updated

Skip dependencies:

uppd --skip foo bar

Allow upgrade to pre releases:

uppd --pre foo bar

The following settings (with defaults) can be overwritten in the infile:

[tool.uppd]
match_operators = ["==", "<=", "~="]
skip = []
dev = []
pre = []
post = ["*"]
index_url = "https://pypi.org"

Development

Setup, run tests and release:

pip install -e .[dev]
brundle
pytest
bouillon release

Credits

This project aims to enable a similar workflow as pur for requirements.txt files

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

uppd-1.5.0.tar.gz (10.2 kB view details)

Uploaded Source

Built Distribution

uppd-1.5.0-py3-none-any.whl (7.0 kB view details)

Uploaded Python 3

File details

Details for the file uppd-1.5.0.tar.gz.

File metadata

  • Download URL: uppd-1.5.0.tar.gz
  • Upload date:
  • Size: 10.2 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/5.1.1 CPython/3.12.7

File hashes

Hashes for uppd-1.5.0.tar.gz
Algorithm Hash digest
SHA256 644e04e1b5cac9ad4778c49581cbf81cdaca5b471120df0e65bd675e5a7be149
MD5 372f4f65ced5a88c829ddd5d748b3687
BLAKE2b-256 71268ba4f70c7c23d4deb0407560e3a32e541a5e48cb9e6c98dad01cd7e74c93

See more details on using hashes here.

File details

Details for the file uppd-1.5.0-py3-none-any.whl.

File metadata

  • Download URL: uppd-1.5.0-py3-none-any.whl
  • Upload date:
  • Size: 7.0 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/5.1.1 CPython/3.12.7

File hashes

Hashes for uppd-1.5.0-py3-none-any.whl
Algorithm Hash digest
SHA256 127a7018ca1b865c47658dfd56dba4567e8d59f4a1c92f373ea975b815ba837f
MD5 a1cccc84fe29b4c2705d646b0a7ccf23
BLAKE2b-256 bec4c5ad1039e9e6fb543cdf0f2ef4fbfa3032691bc68df2087a3d5ba5bdf739

See more details on using hashes here.

Supported by

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