diff --git a/crates/uv/src/commands/publish.rs b/crates/uv/src/commands/publish.rs index edd7e332f..a39f73768 100644 --- a/crates/uv/src/commands/publish.rs +++ b/crates/uv/src/commands/publish.rs @@ -81,6 +81,10 @@ pub(crate) async fn publish( } }; + if password.is_some() && username.is_none() { + bail!("You need to provide a username with a password, use `--token` for tokens"); + } + for (file, filename) in files { let size = fs_err::metadata(&file)?.len(); let (bytes, unit) = human_readable_bytes(size);