From 884d9ab32bbca7a8ec5c7ee7d42cbde0e7e6babf Mon Sep 17 00:00:00 2001 From: nsfisis Date: Tue, 5 May 2026 19:38:29 +0900 Subject: refactor(core): replace ComposerConfig with typed Config struct Config uses serde with kebab-case field mapping; known properties are strongly-typed fields and unknown keys flow into an extra BTreeMap. resolve_references is moved to the new config module. --- crates/mozart/src/commands/archive.rs | 13 ++++--------- 1 file changed, 4 insertions(+), 9 deletions(-) (limited to 'crates/mozart/src/commands/archive.rs') diff --git a/crates/mozart/src/commands/archive.rs b/crates/mozart/src/commands/archive.rs index a075ade..4386e16 100644 --- a/crates/mozart/src/commands/archive.rs +++ b/crates/mozart/src/commands/archive.rs @@ -104,15 +104,10 @@ pub async fn execute( let (config_archive_format, config_archive_dir) = match composer.as_ref() { Some(c) => { let cfg = c.config(); - let fmt = cfg - .get("archive-format") - .and_then(|v| v.as_str()) - .map(|s| s.to_string()); - let dir = cfg - .get("archive-dir") - .and_then(|v| v.as_str()) - .map(|s| s.to_string()); - (fmt, dir) + ( + Some(cfg.archive_format.clone()), + Some(cfg.archive_dir.clone()), + ) } None => (None, None), }; -- cgit v1.3.1