Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion crates/uv-cli/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -3426,7 +3426,7 @@ pub struct TreeArgs {
/// Omit the development dependency group.
///
/// This option is an alias for `--no-group dev`.
#[arg(long, overrides_with("dev"), conflicts_with = "invert")]
#[arg(long, overrides_with("dev"))]
pub no_dev: bool,

/// Include dependencies from the specified dependency group.
Expand Down
13 changes: 13 additions & 0 deletions crates/uv/tests/it/tree.rs
Original file line number Diff line number Diff line change
Expand Up @@ -578,6 +578,7 @@ fn dev_dependencies_inverted() -> Result<()> {
version = "0.1.0"
requires-python = ">=3.12"
dependencies = ["iniconfig"]

[tool.uv]
dev-dependencies = ["anyio"]
"#,
Expand All @@ -601,6 +602,18 @@ fn dev_dependencies_inverted() -> Result<()> {
"###
);

uv_snapshot!(context.filters(), context.tree().arg("--universal").arg("--invert").arg("--no-dev"), @r###"
success: true
exit_code: 0
----- stdout -----
iniconfig v2.0.0
└── project v0.1.0

----- stderr -----
Resolved 5 packages in [TIME]
"###
);

// `uv tree` should update the lockfile
let lock = context.read("uv.lock");
assert!(!lock.is_empty());
Expand Down