1
Fork 0
mirror of https://github.com/RGBCube/nu_scripts synced 2025-07-30 21:57:44 +00:00
nu_scripts/custom-completions/uv
Nguyễn Hồng Quân c0e88c5756
Eliminate duplication in uv completion script (#1112)
This script was generated by uv itself (then add more modification to
provide group completion), but has too many duplication. This PR is to
fix that.
2025-05-03 08:38:00 -05:00
..
README.md Add completion for uv Python package manager (#1071) 2025-03-13 06:14:11 -05:00
uv-completions.nu Eliminate duplication in uv completion script (#1112) 2025-05-03 08:38:00 -05:00

uv completions

uv is a Python package and project manager, known for its speed.

Though uv can generate its Nu completion script via uv generate-shell-completion, this script can only provide static choices, not dynamic choices from pyproject.toml file.

Install completion script

First, if you installed the script generated by uv generate-shell-completion, please remove it to avoid conflict.

Method 1: Use from Git repo

  • git clone https://github.com/nushell/nu_scripts.git

  • Add this to $nu.config-path file.

    source repo/custom-completions/uv/uv-completions.nu
    

Method 2: Selectively copy

  • Copy the uv-completions.nu to Nu standard place.

    cp custom-completions/uv/uv-completions.nu ($nu.data-dir | path join 'completions')
    
  • Open $nu.config-path file and add this:

    source uv-completions.nu