Commit 7859d692 authored by Alexandre Pere's avatar Alexandre Pere

Fixes bug in batch

parent aa15ed9d
...@@ -277,9 +277,12 @@ fn extract_args_iter(matches: &clap::ArgMatches) -> Result<Box<dyn std::iter::It ...@@ -277,9 +277,12 @@ fn extract_args_iter(matches: &clap::ArgMatches) -> Result<Box<dyn std::iter::It
.map(|l| misc::expand_template_string(&l).into_iter()) .map(|l| misc::expand_template_string(&l).into_iter())
.flatten())) .flatten()))
} else { } else {
let content = matches.value_of("ARGUMENTS").unwrap(); let content = match matches.values_of("ARGUMENTS"){
debug!("Arguments tempolate found: {}", content); Some(it) => it.fold(String::new(), |acc, arg| format!("{} {}", acc, arg)),
Ok(Box::new(misc::expand_template_string(content).into_iter())) None => "".to_owned()
};
debug!("Arguments template found: {}", content);
Ok(Box::new(misc::expand_template_string(&content).into_iter()))
} }
} }
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment