Skip to content

Commit

Permalink
feat: add template name and path in error
Browse files Browse the repository at this point in the history
  • Loading branch information
InioX committed Dec 20, 2023
1 parent eed7812 commit ca7f886
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/util/template.rs
Original file line number Diff line number Diff line change
Expand Up @@ -214,7 +214,7 @@ impl Template {
}

let data = engine.template(name).render(upon::value!{ colors: &colors, image: image, custom: &custom, }).to_string().map_err(|error| {
let message = format!("{:#}", error);
let message = format!("[{} - {}]\n{:#}", name, input_path_absolute.display(), error);
Report::new(error).wrap_err(message)
})?;

Expand Down

0 comments on commit ca7f886

Please sign in to comment.