uv_h.md
"/home/yossef/notes/packages/uv_h.md.md"
path: packages/uv_h.md.md
- **fileName**: uv_h.md
- **Created on**: 2025-06-08 20:27:11
this uv package is alternative for pip and pipx in python for fast
simple response and cached packages better than pip
uv is package using with python for download packages and remove and update
this the output for tldr:
uv
A fast Python package and project manager.
Some subcommands such as `tool` and `python` have their own usage documentation.
More information: https://docs.astral.sh/uv/reference/cli.
- Create a new Python project in the current directory:
uv init
- Create a new Python project at the specified path:
uv init path/to/directory
- Add a new dependency to the project:
uv add package
- Remove a dependency from the project:
uv remove package
- Run a script in the project's environment:
uv run path/to/script.py
- Run a command in the project's environment:
uv run command
- Update a project's environment from pyproject.toml:
uv sync
- Create a lock file for the project's dependencies:
uv lock
For install
# On macOS and Linux.
curl -LsSf https://astral.sh/uv/install.sh | sh
the main structure for uv folder when run commend
uv init
inside a folder
➜ foo git:(master) ✗ tree
[ 142] ./
├── [ 111] main.py
├── [ 175] pyproject.toml
├── [ 0] README.md
└── [ 33K] uv.lock
1 directory, 4 files
-
so start with main.py file is the main running file in project run using
uv run main.py -
pyproject.toml is important to store information about the packages you
build or software or program you do and the package need for the project
think of it like requirements.txt -
now the next one is uv.lock is more specific about the dependence's for
the project like version and lock or not and more information about each package
you download and use in project -
and there is .venv folder the venv for all packages to store the package
you installcontinue:./uv_docker_h.md.md
before:[[]]