From cc8f22ff7f1d9ed32e14f5b59a5498f8aa653091 Mon Sep 17 00:00:00 2001 From: nsfisis Date: Mon, 23 Feb 2026 01:45:14 +0900 Subject: fix(show): validate option combinations and support --ignore wildcards - Reject invalid option combinations: --direct with --all/--platform/--available, --tree with --all/--available/--latest/--path, --self with package argument - Reject unsupported --format values (only "text" and "json" allowed) - Warn when --ignore is used without --outdated - Support wildcard patterns in --ignore values via matches_wildcard Co-Authored-By: Claude Opus 4.6 --- crates/mozart/src/commands/require.rs | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) (limited to 'crates/mozart/src/commands/require.rs') diff --git a/crates/mozart/src/commands/require.rs b/crates/mozart/src/commands/require.rs index 16d865f..ef5ff04 100644 --- a/crates/mozart/src/commands/require.rs +++ b/crates/mozart/src/commands/require.rs @@ -679,9 +679,10 @@ pub async fn execute( eprintln!("Warning: Failed to revert composer.json: {revert_err}"); } if let Some(ref lock_content) = original_composer_lock - && let Err(revert_err) = std::fs::write(&lock_path_for_backup, lock_content) { - eprintln!("Warning: Failed to revert composer.lock: {revert_err}"); - } + && let Err(revert_err) = std::fs::write(&lock_path_for_backup, lock_content) + { + eprintln!("Warning: Failed to revert composer.lock: {revert_err}"); + } } return Err(mozart_core::exit_code::bail( mozart_core::exit_code::DEPENDENCY_RESOLUTION_FAILED, -- cgit v1.3.1