From fa7d49282bf2d7b893c5dfe296893f7fc8507a58 Mon Sep 17 00:00:00 2001 From: fusillicode Date: Sat, 25 Jan 2020 15:54:56 +0100 Subject: [PATCH] Restun exit code for generate_and_execute? --- src/exec/mod.rs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/exec/mod.rs b/src/exec/mod.rs index 8554f28..091e989 100644 --- a/src/exec/mod.rs +++ b/src/exec/mod.rs @@ -146,7 +146,7 @@ impl CommandTemplate { /// /// Using the internal `args` field, and a supplied `input` variable, a `Command` will be /// build. Once all arguments have been processed, the command is executed. - pub fn generate_and_execute(&self, input: &Path, out_perm: Arc>) { + pub fn generate_and_execute(&self, input: &Path, out_perm: Arc>) -> ExitCode { let input = Self::prepare_path(input); let mut cmd = Command::new(self.args[0].generate(&input).as_ref()); @@ -154,7 +154,7 @@ impl CommandTemplate { cmd.arg(arg.generate(&input).as_ref()); } - execute_command(cmd, &out_perm); + execute_command(cmd, &out_perm) } pub fn in_batch_mode(&self) -> bool {