change: compile_article now takes references to pathbufs
This commit is contained in:
parent
32778e8fff
commit
a5b42ea97a
2 changed files with 3 additions and 3 deletions
|
|
@ -7,8 +7,8 @@ use typst_html::{HtmlAttr, HtmlDocument, HtmlElement, HtmlNode};
|
|||
|
||||
|
||||
pub fn compile_article(
|
||||
article_dir: PathBuf,
|
||||
prepend: Option<PathBuf>,
|
||||
article_dir: &PathBuf,
|
||||
prepend: &Option<PathBuf>,
|
||||
) -> Result<(), Box<dyn std::error::Error + Send + Sync>> {
|
||||
|
||||
let template_file = article_dir.join("index.typ");
|
||||
|
|
|
|||
|
|
@ -21,7 +21,7 @@ fn main() {
|
|||
|
||||
let args = Args::parse();
|
||||
|
||||
if let Err(e) = compile_article(args.dir, args.prepend) {
|
||||
if let Err(e) = compile_article(&args.dir, &args.prepend) {
|
||||
eprintln!("{e}");
|
||||
std::process::exit(1);
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue