uv/docs
Charlie Marsh 792dc9d1c5
Add uv sync --script (#11361)
## Summary

The environment is located at a stable path within the cache, based on
the script's absolute path.

If a lockfile exists for the script, then we use our standard lockfile
semantics (i.e., update the lockfile if necessary, etc.); if not, we
just do a `uv pip sync` (roughly).

Example usage:

```
❯ uv init --script hello.py
Initialized script at `hello.py`

❯ uv add --script hello.py requests
Updated `hello.py`

❯ cargo run sync --script hello.py
Using script environment at: /Users/crmarsh/.cache/uv/environments-v1/hello-84e289fe3f6241a0
Resolved 5 packages in 3ms
Installed 5 packages in 12ms
 + certifi==2025.1.31
 + charset-normalizer==3.4.1
 + idna==3.10
 + requests==2.32.3
 + urllib3==2.3.0
```

Closes https://github.com/astral-sh/uv/issues/6637.
2025-02-12 16:02:16 +00:00
..
.overrides Add `last updated` for document (#11164) 2025-02-03 22:28:47 -05:00
assets Add static assets to docs pages (#6951) 2024-09-02 20:00:30 -04:00
concepts Add note about available versions (#11331) 2025-02-07 16:10:05 -06:00
configuration Add NO_BINARY and NO_BINARY_PACKAGE environment variables (#11399) 2025-02-10 21:11:46 +00:00
getting-started Bump version to v0.5.30 (#11405) 2025-02-10 21:42:31 +00:00
guides Update scripts docs with package indexes (#11443) 2025-02-12 07:52:22 -06:00
js Add support for anchor redirects with client-side js (#9212) 2024-11-19 22:32:43 -06:00
pip add instructions for deactivating an environment (#11200) 2025-02-03 22:16:41 +00:00
reference Add uv sync --script (#11361) 2025-02-12 16:02:16 +00:00
stylesheets Improve the styling of collapsible nav items (#10692) 2025-01-16 15:02:43 -06:00
.gitignore Add structured documentation (#4426) 2024-06-26 11:28:42 -05:00
index.md Fix windows installation instructions mismatch (#11380) 2025-02-10 21:42:50 +01:00
requirements-insiders.in Reference the root requirements from the insiders requirements file (#5105) 2024-07-16 09:51:16 -05:00
requirements-insiders.txt Move content from the mkdocs.public.yml into the template (#11246) 2025-02-05 16:13:46 +00:00
requirements.in Add `last updated` for document (#11164) 2025-02-03 22:28:47 -05:00
requirements.txt Add `last updated` for document (#11164) 2025-02-03 22:28:47 -05:00