manzt / juv

Reproducible Jupyter notebooks, powered by uv.
MIT License
80 stars 2 forks source link

Add `--pin` flag for `juv add` #51

Closed manzt closed 1 week ago

manzt commented 1 week ago

Adds a --pin flag to juv add to resolve packages to a specific version. This will effectively pin the package in the notebook/script to whatever the resolver finds at the time of the command.

Works with both scripts and notebooks.

uvx juv init
uvx juv add Untitled.ipynb numpy polars --pin # adds numpy==2.1.3 polars==1.13.1
uv init --script foo.py
uvx juv add foo.py numpy polars --pin