{{tag>[python]}}
====== uvx ======
npx처럼 python의 명령줄 실행 도구.
패키지를 설치하지 않아도 임시 환경에서 실행 가능.
===== USAGE =====
* ''**uvx** [OPTIONS] [COMMAND]''
* [OPTIONS]
* [COMMAND]: 패키지
* ''python file.py'': file.py을 임시 환경에서 실행
Usage: uvx [OPTIONS] [COMMAND]
Options:
--from Use the given package to provide the command
--with Run with the given packages installed
--with-editable Run with the given packages installed in editable mode
--with-requirements Run with all packages listed in the given `requirements.txt` files
-c, --constraints Constrain versions using the given requirements files [env: UV_CONSTRAINT=]
-b, --build-constraints Constrain build dependencies using the given requirements files when building source distributions [env: UV_BUILD_CONSTRAINT=]
--overrides Override versions using the given requirements files [env: UV_OVERRIDE=]
--isolated Run the tool in an isolated virtual environment, ignoring any already-installed tools
--env-file Load environment variables from a `.env` file [env: UV_ENV_FILE=]
--no-env-file Avoid reading environment variables from a `.env` file [env: UV_NO_ENV_FILE=]
-V, --version Display the uvx version
Index options:
--index The URLs to use when resolving dependencies, in addition to the default index [env: UV_INDEX=]
--default-index The URL of the default package index (by default: ) [env: UV_DEFAULT_INDEX=]
-i, --index-url (Deprecated: use `--default-index` instead) The URL of the Python package index (by default: ) [env: UV_INDEX_URL=]
--extra-index-url (Deprecated: use `--index` instead) Extra URLs of package indexes to use, in addition to `--index-url` [env: UV_EXTRA_INDEX_URL=]
-f, --find-links Locations to search for candidate distributions, in addition to those found in the registry indexes [env: UV_FIND_LINKS=]
--no-index Ignore the registry index (e.g., PyPI), instead relying on direct URL dependencies and those provided via `--find-links`
--index-strategy The strategy to use when resolving against multiple index URLs [env: UV_INDEX_STRATEGY=] [possible values: first-index, unsafe-first-match, unsafe-best-match]
--keyring-provider Attempt to use `keyring` for authentication for index URLs [env: UV_KEYRING_PROVIDER=] [possible values: disabled, subprocess]
Resolver options:
-U, --upgrade Allow package upgrades, ignoring pinned versions in any existing output file. Implies `--refresh`
-P, --upgrade-package Allow upgrades for a specific package, ignoring pinned versions in any existing output file. Implies `--refresh-package`
--resolution The strategy to use when selecting between the different compatible versions for a given package requirement [env: UV_RESOLUTION=] [possible values: highest, lowest, lowest-direct]
--prerelease The strategy to use when considering pre-release versions [env: UV_PRERELEASE=] [possible values: disallow, allow, if-necessary, explicit, if-necessary-or-explicit]
--fork-strategy The strategy to use when selecting multiple versions of a given package across Python versions and platforms [env: UV_FORK_STRATEGY=] [possible values: fewest, requires-python]
--exclude-newer Limit candidate packages to those that were uploaded prior to the given date [env: UV_EXCLUDE_NEWER=]
--no-sources Ignore the `tool.uv.sources` table when resolving dependencies. Used to lock against the standards-compliant, publishable package metadata, as opposed to using any workspace, Git, URL, or local path sources
Installer options:
--reinstall Reinstall all packages, regardless of whether they're already installed. Implies `--refresh`
--reinstall-package Reinstall a specific package, regardless of whether it's already installed. Implies `--refresh-package`
--link-mode The method to use when installing packages from the global cache [env: UV_LINK_MODE=] [possible values: clone, copy, hardlink, symlink]
--compile-bytecode Compile Python files to bytecode after installation [env: UV_COMPILE_BYTECODE=]
Build options:
-C, --config-setting Settings to pass to the PEP 517 build backend, specified as `KEY=VALUE` pairs
--no-build-isolation Disable isolation when building source distributions [env: UV_NO_BUILD_ISOLATION=]
--no-build-isolation-package Disable isolation when building source distributions for a specific package
--no-build Don't build source distributions [env: UV_NO_BUILD=]
--no-build-package Don't build source distributions for a specific package [env: UV_NO_BUILD_PACKAGE=]
--no-binary Don't install pre-built wheels [env: UV_NO_BINARY=]
--no-binary-package Don't install pre-built wheels for a specific package [env: UV_NO_BINARY_PACKAGE=]
Cache options:
-n, --no-cache Avoid reading from or writing to the cache, instead using a temporary directory for the duration of the operation [env: UV_NO_CACHE=]
--cache-dir Path to the cache directory [env: UV_CACHE_DIR=]
--refresh Refresh all cached data
--refresh-package Refresh cached data for a specific package
Python options:
-p, --python The Python interpreter to use to build the run environment. [env: UV_PYTHON=]
--managed-python Require use of uv-managed Python versions [env: UV_MANAGED_PYTHON=]
--no-managed-python Disable use of uv-managed Python versions [env: UV_NO_MANAGED_PYTHON=]
--no-python-downloads Disable automatic downloads of Python. [env: "UV_PYTHON_DOWNLOADS=never"]
Global options:
-q, --quiet... Use quiet output
-v, --verbose... Use verbose output
--color Control the use of color in output [possible values: auto, always, never]
--native-tls Whether to load TLS certificates from the platform's native certificate store [env: UV_NATIVE_TLS=]
--offline Disable network access [env: UV_OFFLINE=]
--allow-insecure-host Allow insecure connections to a host [env: UV_INSECURE_HOST=]
--no-progress Hide all progress outputs [env: UV_NO_PROGRESS=]
--directory Change to the given directory prior to running the command
--project Run the command within the given project directory [env: UV_PROJECT=]
--config-file The path to a `uv.toml` file to use for configuration [env: UV_CONFIG_FILE=]
--no-config Avoid discovering configuration files (`pyproject.toml`, `uv.toml`) [env: UV_NO_CONFIG=]
-h, --help Display the concise help for this command