From c58fee1ef37b0f86fa250331247a305cbf9bc360 Mon Sep 17 00:00:00 2001 From: 魏曹先生 <1992414357@qq.com> Date: Mon, 29 Jun 2026 04:14:56 +0800 Subject: fix(deps): bump just_template to 0.2.0 and migrate to new API --- Cargo.lock | 16 ++++++++++++++-- Cargo.toml | 2 +- mingling_core/src/builds/comp.rs | 6 +++--- 3 files changed, 18 insertions(+), 6 deletions(-) diff --git a/Cargo.lock b/Cargo.lock index 7e1f179..087c95c 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -344,11 +344,23 @@ checksum = "5454cda0d57db59778608d7a47bff5b16c6705598265869fb052b657f66cf05e" [[package]] name = "just_template" -version = "0.1.3" +version = "0.2.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "db3edb658c34b10b69c4b3b58f7ba989cd09c82c0621dee1eef51843c2327225" +checksum = "4fb99a3c1dee7299c57b26ef927f15535da0fbc93d6deb1d1114cae1337be4fb" dependencies = [ "just_fmt", + "just_template_macros", +] + +[[package]] +name = "just_template_macros" +version = "0.2.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "1471eb68722ecefeb71debdde2859e8725341f171d3f42b3a98a0862ad19416e" +dependencies = [ + "proc-macro2", + "quote", + "syn", ] [[package]] diff --git a/Cargo.toml b/Cargo.toml index 95cb488..b19bfb9 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -22,7 +22,7 @@ mingling_macros = { path = "mingling_macros", default-features = false } mingling_pathf = { path = "mingling_pathf", default-features = false } just_fmt = "0.1.2" -just_template = "0.1.3" +just_template = "0.2.0" serde = { version = "1.0.228", features = ["derive"] } serde_json = "1.0.150" diff --git a/mingling_core/src/builds/comp.rs b/mingling_core/src/builds/comp.rs index b826531..2abb1e1 100644 --- a/mingling_core/src/builds/comp.rs +++ b/mingling_core/src/builds/comp.rs @@ -1,6 +1,6 @@ use std::path::PathBuf; -use just_template::tmpl_param; +use just_template::tmpl; use crate::ShellFlag; @@ -86,7 +86,7 @@ pub fn build_comp_script_to( ) -> Result<(), std::io::Error> { let (tmpl_str, ext) = get_tmpl(shell_flag); let mut tmpl = just_template::Template::from(tmpl_str); - tmpl_param!(tmpl, bin_name = bin_name); + tmpl!(bin_name = bin_name); let target_path = std::path::PathBuf::from(target_dir); std::fs::create_dir_all(&target_path)?; let output_path = target_path.join(format!("{bin_name}_comp{ext}")); @@ -112,7 +112,7 @@ pub fn build_comp_script_to_file( ) -> Result<(), std::io::Error> { let (tmpl_str, _ext) = get_tmpl(shell_flag); let mut tmpl = just_template::Template::from(tmpl_str); - tmpl_param!(tmpl, bin_name = bin_name); + tmpl!(bin_name = bin_name); std::fs::write(output_path.into(), tmpl.to_string()) } -- cgit