How to install Python CLI tools without Python
uvx.sh provides installation scripts for any Python tool on PyPIThe Python Package Index, the public repository where Python packages are published and downloaded from. "pip install requests" fetches requests from PyPI. Learn more โ . Use it to install tools like Ruff or pre-commit without having uv or Python already installed.
An isolated pytest installation does not include a project’s dependencies. For project tests, use the project’s environment through running tests with uv.
Installing a Tool
Replace {package} with any PyPI package name:
curl -LsSf https://uvx.sh/{package}/install.sh | shFor example, to install ruff:
curl -LsSf https://uvx.sh/ruff/install.sh | shInstalling a Specific Version
Add the version number to the URL path:
curl -LsSf https://uvx.sh/ruff/0.8.3/install.sh | shForcing Reinstallation
To overwrite an existing installation, pass the --force flag:
curl -LsSf https://uvx.sh/ruff/install.sh | sh -s -- --forceUsing a Custom Package Index
To install from a private or alternative package index:
curl -LsSf https://uvx.sh/cmake/install.sh | sh -s -- --index https://download.pytorch.org/whl/cpu