Skip to content

an extremely short intro to using uv for python package mangement

Notifications You must be signed in to change notification settings

TrelisResearch/learn-uv

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

2 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Things you can do with uv

Full docs here.

Basic

  1. Create a virtual environment
uv venv
  1. Install dependencies
uv install -r requirements.txt

or

uv pip install matplotlib numpy
uv pip freeze > requirements.txt
  1. Run a command

No need to activate the venv, uv will by default run in the environment set by VIRTUAL_ENV, then CONDA_PREFIX if present, and then .venv .

uv run draw-circle.py

BONUS

  1. Use a specific version of python when setting up the venv:
uv venv --python 3.12.4

uv will install it if not present on your system (btw, it will be a uv install, not system-wide).

About

an extremely short intro to using uv for python package mangement

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages