Skip to main content

Sort uv's dependencies alphabetically

Project description

uv-sort

PyPI version

Sort uv's dependencies alphabetically.

The following sections are supported:

  • dependency-groups
  • project.dependencies
  • project.optional-dependencies
  • tool.uv.dev-dependencies
  • tool.uv.sources

Installation

pip install uv-sort
# or
uv add uv-sort

[!Note] uv users do not need to install uv-sort and can instead use uv tools. See usage examples.

Usage

# sort dependencies in pyproject.toml in the current working directory
$ uv-sort
# or you can specify the path
$ uv-sort /path/to/pyproject.toml
# or using uv tools (no install)
$ uvx uv-sort

Options

  • --check: Check if dependencies are sorted and exit with a non-zero status code when they are not.
  • --dry-run: Output the modified file to stdout without modifying the file.

With pre-commit

repos:
  - repo: https://github.com/ninoseki/uv-sort
    rev: "" # Use the sha / tag you want to point at
    hooks:
      - id: uv-sort

With Lefthook

pre-commit:
  commands:
    uv-sort:
      run: uv-sort {staged_files}
      glob: "pyproject.toml"

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

uv_sort-0.7.1.tar.gz (21.9 kB view details)

Uploaded Source

Built Distribution

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

uv_sort-0.7.1-py3-none-any.whl (4.5 kB view details)

Uploaded Python 3

File details

Details for the file uv_sort-0.7.1.tar.gz.

File metadata

  • Download URL: uv_sort-0.7.1.tar.gz
  • Upload date:
  • Size: 21.9 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.13

File hashes

Hashes for uv_sort-0.7.1.tar.gz
Algorithm Hash digest
SHA256 085af2f7ec36f12f0c856812a911bc1534134377989f13b9c52810222ff19a47
MD5 543ca53f8c092f0dc135f528e9e79933
BLAKE2b-256 245d0a5c6b997437ceebe0ef813442e29dcc0b294298e153629a72ba463f690f

See more details on using hashes here.

Provenance

The following attestation bundles were made for uv_sort-0.7.1.tar.gz:

Publisher: publish.yml on ninoseki/uv-sort

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

File details

Details for the file uv_sort-0.7.1-py3-none-any.whl.

File metadata

  • Download URL: uv_sort-0.7.1-py3-none-any.whl
  • Upload date:
  • Size: 4.5 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.13

File hashes

Hashes for uv_sort-0.7.1-py3-none-any.whl
Algorithm Hash digest
SHA256 14098ecd46b32ed1b351a6757f2b7591009b6992cf91e762bd83bf9adfab499c
MD5 bf97689ecdf648796c6fdb682815a5bb
BLAKE2b-256 f5fdc617a8edf311d8e5082f25b71fc18eac8846d9a374bff23a003052ee1d54

See more details on using hashes here.

Provenance

The following attestation bundles were made for uv_sort-0.7.1-py3-none-any.whl:

Publisher: publish.yml on ninoseki/uv-sort

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