152 Commits

Author SHA1 Message Date
Zanie Blue
8d66718077 Bump version to 0.2.36 (#6060) 2024-08-13 12:05:11 -05:00
Zanie Blue
e8876ada6d Fix some outdated documentation discussing Python environments (#6058)
Starting on https://github.com/astral-sh/uv/issues/5966 noticed various
problems
2024-08-13 11:47:39 -05:00
eth3lbert
ef948619ee Hide python options in uv tool list help (#6003)
## Summary

Closes #5982 .

## Test Plan

```
cargo run tool list --help
```

---------

Co-authored-by: Zanie Blue <contact@zanie.dev>
2024-08-13 11:21:44 -05:00
Zanie Blue
d20314038f Move help documentation into dedicated page (#6057) 2024-08-13 11:09:32 -05:00
Zanie Blue
f6f1bd2f14 Improve top-level help for uv tool commands (#5983)
More work needs to be done for all of the options
2024-08-12 17:35:50 +00:00
Theo BABILON
070d5b7402 Fixed projects guide typo (#6033)
Sorry for spam, also noticed this tiny repetition

Co-authored-by: tbabilon <theo.babilon@mlp.com>
2024-08-12 07:09:11 -05:00
Theo BABILON
9eead68168 Fixed tools guide typo (#6027)
Noticed this tiny typo when reading the tools guide documentation

Co-authored-by: tbabilon <theo.babilon@mlp.com>
2024-08-12 07:17:38 -04:00
Ahmed Ilyas
2d53e35e39 Support PEP 723 scripts in uv add and uv remove (#5995)
## Summary

Resolves https://github.com/astral-sh/uv/issues/4667

## Test Plan

`cargo test`
2024-08-11 01:40:59 +00:00
Charlie Marsh
cd0171a2ed Remove editable: false support (#5987)
## Summary

This doesn't actually work yet. We'll re-add it in the future.

Closes #5958.
2024-08-09 20:59:23 -04:00
Zanie Blue
e097f948c9 Bump version to 0.2.35 (#5984) 2024-08-09 19:21:06 -05:00
Zanie Blue
921050d747 Improve the uv sync CLI documentation (#5930) 2024-08-09 14:46:32 -05:00
Zanie Blue
d6c587c21c Improve the uv python CLI documentation (#5961) 2024-08-09 14:46:21 -05:00
Charlie Marsh
f89403f4f6 Retain and respect settings in tool upgrades (#5937)
## Summary

We now persist the `ResolverInstallerOptions` when writing out a tool
receipt. When upgrading, we grab the saved options, and merge with the
command-line arguments and user-level filesystem settings (CLI > receipt
> filesystem).
2024-08-09 18:21:49 +00:00
Zanie Blue
44f94524f3 Document virtual environment discovery (#5965) 2024-08-09 18:15:21 +00:00
Zanie Blue
4df0fe9a01 Update the interface for declaring Python download preferences (#5936)
The loose consensus is that "fetch" doesn't have much meaning and that a
boolean flag makes more sense from the command line.

1. Adds `--allow-python-downloads` (hidden, default) and
`--no-python-downloads` to the CLI to quickly enable or disable
downloads
2. Deprecates `--python-fetch` in favor of the options from (1)
3. Removes  `python-fetch` in favor of a `python-downloads` setting
5. Adds a `never` variant to the enum, allowing even explicit installs
to be disabled via the configuration file

## Test plan

I tested this with various `pyproject.toml`-level settings and `uv venv
--preview --python 3.12.2` and `uv python install 3.12.2` with and
without the new CLI flags.
2024-08-09 13:10:19 -05:00
Zanie Blue
db0b44b88c Move some documents to relevant sections (#5968) 2024-08-09 17:31:10 +00:00
Zanie Blue
3228fc5f35 Improve the uv venv CLI documentation (#5963)
This was actually in pretty good shape already!
2024-08-09 12:15:22 -05:00
Zanie Blue
4330f9718b Improve the uv lock CLI documentation (#5932) 2024-08-09 08:51:03 -05:00
Charlie Marsh
7a0b610c19 Document the tool upgrade command (#5947) 2024-08-09 08:19:38 -05:00
Charlie Marsh
fd1d508108 Make --upgrade imply --refresh (#5943)
## Summary

I think this seems reasonable... Otherwise, we might not go back to PyPI
to revalidate the list of available versions despite the user passing
`--upgrade`.
2024-08-08 20:11:31 -04:00
Zanie Blue
54a85c0cfd Add caveat about pip interface name (#5940)
I'm not sure if this is worthwhile, but it is a point of confusion
sometimes.
2024-08-08 22:01:08 +00:00
Charlie Marsh
88ece8b791 Search beyond workspace root when discovering configuration (#5931)
## Summary

Previously, we wouldn't respect configuration files in directories
_above_ a workspace root. But this is somewhat problematic, because any
`pyproject.toml` will define a workspace root...

Instead, I think we should _start_ the search at the workspace root, but
go above it if necessary.

Closes: #5929.

See: https://github.com/astral-sh/uv/pull/4295.
2024-08-08 17:05:02 -04:00
Ahmed Ilyas
cbc3274848 Add uv tool upgrade command (#5197)
## Summary

Resolves #5188. Most of the changes involve creating a new function in
`tool/common.rs` to contain the common functionality previously found in
`tool/install.rs`.

## Test Plan

`cargo test`

```console
❯ ./target/debug/uv tool upgrade black
warning: `uv tool upgrade` is experimental and may change without warning.
Resolved 6 packages in 25ms
Uninstalled 1 package in 3ms
Installed 1 package in 19ms
 - black==23.1.0
 + black==24.4.2
Installed 2 executables: black, blackd
```
2024-08-08 16:48:14 -04:00
Zanie Blue
bf0497e652 Add CLI flags to reference documentation (#5926)
Oopsies, options are only arguments that take values in Clap-land

Closes https://github.com/astral-sh/uv/issues/5924
2024-08-08 18:51:27 +00:00
Charlie Marsh
dd1bcf8ab9 Ignore local configuration in tool commands (#5923)
## Summary

If you're running a user-level command, we shouldn't respect the local
`pyproject.toml` or `uv.toml`.
2024-08-08 14:25:12 -04:00
Zanie Blue
d2681320d3 Improve the CLI documentation for uv remove (#5916)
Also, renames a `requirements` variable to `packages` for clarity and
fixes the definition of `frozen` for `uv add`.
2024-08-08 13:12:49 -05:00
Zanie Blue
eb6251e0ed Improve the CLI documentation for uv add (#5914) 2024-08-08 10:52:38 -05:00
Adrian Sampson
61b0a88107 Docs: Fix link to tools concept page (#5906)
This link previously went to the wrong "concept" page; it now goes to
the one the page intended.
2024-08-08 12:38:24 +00:00
Ahmed Ilyas
acbd367ead Support no-build-isolation-package (#5894)
## Summary

Resolves #5831 

## Test Plan

`cargo test`
2024-08-08 01:35:56 +00:00
Charlie Marsh
f7110e0a07 Enable mirror for python-build-standalone downloads (#5719)
## Summary

This came up again recently, so decided to do it real quick.

Closes https://github.com/astral-sh/uv/issues/5224.
2024-08-07 21:34:19 -04:00
Charlie Marsh
c681c5a33c Bump version to v0.2.34 (#5889) 2024-08-07 16:33:53 -04:00
Zanie Blue
c95bf76dfe Replace uv help python references in CLI documentation with links (#5871)
Following #5869, the documentation has some less-than-helpful
suggestions to use `uv help python` for details — we should link to the
`uv python` section instead.
2024-08-07 12:21:09 -05:00
Zanie Blue
fe2849af6a Improve CLI documentation for uv tree (#5870) 2024-08-07 16:59:27 +00:00
Zanie Blue
2df2092084 Improve --python CLI documentation (#5869)
Closes #4400
2024-08-07 16:37:10 +00:00
Zanie Blue
32d8ea1698 Improve documentation for uv init CLI (#5862) 2024-08-07 11:26:00 -05:00
Zanie Blue
8998149ac1 Improve CLI documentation for uv run (#5841)
Adds more long-form help to `uv run`, which renders in `uv help run` and
the CLI reference on the website.
2024-08-07 13:26:24 +00:00
Zanie Blue
c34681a74c Use uv installer during build (#5854) 2024-08-07 08:25:26 -05:00
konsti
68f186c409 Resolver internals docs touchups (#5850) 2024-08-07 08:32:31 +00:00
Zanie Blue
345c167774 Fix GitHub cache integration link (#5847)
Unclear why mkdocs does not error on this 404
2024-08-07 02:08:45 +00:00
Zanie Blue
d1614c8f10 Improve CLI documentation for global options (#5834)
Slowly auditing our CLI help text
2024-08-06 20:50:29 -05:00
Zanie Blue
c0c26cc542 Improve display order of top-level commands (#5830)
Closes https://github.com/astral-sh/uv/issues/5702

Since Clap 4, the default order follows the declarations.

Also improves some descriptions.
2024-08-06 16:18:05 -05:00
Charlie Marsh
d8d9b02512 Add --no-build-isolation to uv lock et al (#5829)
## Summary

Closes https://github.com/astral-sh/uv/issues/5742.
2024-08-06 21:11:48 +00:00
Zanie Blue
91792674da Link to the GitHub integration guide from the cache concept (#5828) 2024-08-06 15:48:19 -05:00
Zanie Blue
6a31c80c7e Update the override section with some content from the README (#5820) 2024-08-06 20:23:58 +00:00
Zanie Blue
aad39febe5 Address some feedback in the tools documentation (#5827) 2024-08-06 15:21:18 -05:00
Zanie Blue
f5b477aa4f Update documentation index (#5824) 2024-08-06 15:01:59 -05:00
Zanie Blue
1f7961d6fb Add "next steps" to some early documentation pages (#5825) 2024-08-06 13:48:04 -05:00
Zanie Blue
8cada6cbc9 Fix some console blocks in the environment doc (#5826) 2024-08-06 13:47:49 -05:00
Zanie Blue
12059340de Update resolver reference documentation (#5823) 2024-08-06 13:18:23 -05:00
Zanie Blue
83d6f59e2e Update the resolution concept documentation (#5813) 2024-08-06 12:06:06 -05:00