From d770693bac655da4a21144b4cae7592536fecb8b Mon Sep 17 00:00:00 2001 From: nsfisis Date: Fri, 8 May 2026 23:22:34 +0900 Subject: fix(audit): align with Composer's AuditCommand pipeline - Add mozart-core::advisory::{AuditFormat, AbandonedHandling, AuditConfig} mirroring Composer\Advisory\AuditConfig; reads audit.ignore, audit.ignore-severity, audit.ignore-abandoned, audit.abandoned, audit.block-insecure, audit.block-abandoned, audit.ignore-unreachable from composer.json config with full apply-scope support - Add mozart-registry::advisory::Auditor mirroring Composer\Advisory\Auditor; process_advisories() filters by package name, advisory ID, CVE, source remote ID, and severity; filter_abandoned_packages() respects ignore-abandoned - Add RepositorySet::get_matching_security_advisories() wrapping fetch_security_advisories with version-matching and unreachable-repo tracking - JSON output now includes ignored-advisories and unreachable-repositories keys - --abandoned falls back to audit.abandoned config (was hardcoded to "fail") - --ignore-severity merges with audit.ignore-severity config - --ignore-unreachable ORs with audit.ignore-unreachable config - Move normalize_or_separator into repository/mod.rs alongside version matching Co-Authored-By: Claude Sonnet 4.6 --- crates/mozart/src/commands/base_config.rs | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) (limited to 'crates/mozart/src/commands/base_config.rs') diff --git a/crates/mozart/src/commands/base_config.rs b/crates/mozart/src/commands/base_config.rs index be663d5..bfed161 100644 --- a/crates/mozart/src/commands/base_config.rs +++ b/crates/mozart/src/commands/base_config.rs @@ -11,11 +11,7 @@ pub(crate) struct BaseConfigContext { } impl BaseConfigContext { - pub fn initialize( - global: bool, - file: Option<&str>, - cli: &super::Cli, - ) -> anyhow::Result { + pub fn initialize(global: bool, file: Option<&str>, cli: &super::Cli) -> anyhow::Result { if global && file.is_some() { anyhow::bail!("--file and --global can not be combined"); } -- cgit v1.3.1