mirror of
https://github.com/astral-sh/uv.git
synced 2025-08-04 10:58:28 +00:00
Redact new index credentials in uv add
(#10329)
## Summary Closes https://github.com/astral-sh/uv/issues/10328.
This commit is contained in:
parent
66a603b6c4
commit
243d2f8d5d
2 changed files with 88 additions and 1 deletions
|
@ -303,7 +303,7 @@ impl PyProjectTomlMut {
|
|||
.and_then(|url| Url::parse(url).ok())
|
||||
.is_none_or(|url| CanonicalUrl::new(&url) != CanonicalUrl::new(index.url.url()))
|
||||
{
|
||||
let mut formatted = Formatted::new(index.url.to_string());
|
||||
let mut formatted = Formatted::new(index.url.redacted().to_string());
|
||||
if let Some(value) = table.get("url").and_then(Item::as_value) {
|
||||
if let Some(prefix) = value.decor().prefix() {
|
||||
formatted.decor_mut().set_prefix(prefix.clone());
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue