diff --git a/src/cli/drift/mod.rs b/src/cli/drift/mod.rs index 59df915..1e2e668 100644 --- a/src/cli/drift/mod.rs +++ b/src/cli/drift/mod.rs @@ -604,7 +604,7 @@ fn print_drift_entry(entry: &DriftEntry) { println!( " {} {} {} {}{}", cyan.apply_to("●"), - &entry.name, + entry.name, dim.apply_to("—"), cyan.apply_to("local only"), lineage, @@ -649,7 +649,7 @@ fn print_drift_card(entry: &DriftEntry, lineage: &str) { ); let body_drifted = matches!(entry.status, DriftStatus::BodyOnly | DriftStatus::Both); - println!(" {} {}{}", dim.apply_to("┌"), &entry.name, lineage); + println!(" {} {}{}", dim.apply_to("┌"), entry.name, lineage); if frontmatter_drifted { let keys_display = if entry.changed_keys.is_empty() { diff --git a/src/cli/provenance/mod.rs b/src/cli/provenance/mod.rs index 5e974d6..2637c6c 100644 --- a/src/cli/provenance/mod.rs +++ b/src/cli/provenance/mod.rs @@ -77,13 +77,13 @@ pub fn execute( " {} {} {}", dim.apply_to("│"), dim.apply_to("built"), - &details.metadata.started_on + details.metadata.started_on ); println!( " {} {} {} {}", dim.apply_to("│"), dim.apply_to("builder"), - &details.builder.id, + details.builder.id, dim.apply_to(&details.builder.version.forge) ); println!(" {}", dim.apply_to("│")); @@ -94,7 +94,7 @@ pub fn execute( " {} {} {} {}", dim.apply_to("│"), dim.apply_to("input"), - &dependency.uri, + dependency.uri, dim.apply_to(format!("sha256:{short}")) ); } diff --git a/src/yaml/mod.rs b/src/yaml/mod.rs index ff7e24a..fc40b83 100644 --- a/src/yaml/mod.rs +++ b/src/yaml/mod.rs @@ -166,10 +166,7 @@ fn resolve_expression<'yaml>(root: &'yaml Value, expression: &str) -> Option<&'y let mut current = root; for segment in &segments { - match current.get(*segment) { - Some(next) => current = next, - None => return None, - } + current = current.get(*segment)?; } Some(current)