Prechádzať zdrojové kódy

fix(bundler): Return nonzero exit code when errors occur (#233)

* fix(bundler): Return nonzero exit code when errors occur

* fix(bundler): Always exit with exit code 1 when calling print_error
Rajiv Shah 5 rokov pred
rodič
commit
65f1bf96ef
1 zmenil súbory, kde vykonal 2 pridanie a 2 odobranie
  1. 2 2
      cli/tauri-cli/src/bundle/common.rs

+ 2 - 2
cli/tauri-cli/src/bundle/common.rs

@@ -225,7 +225,7 @@ pub fn print_error(error: &crate::Error) -> crate::Result<()> {
       writeln!(output, "{:?}", backtrace)?;
     }
     output.flush()?;
-    Ok(())
+    std::process::exit(1)
   } else {
     let mut output = io::stderr();
     write!(output, "error:")?;
@@ -237,7 +237,7 @@ pub fn print_error(error: &crate::Error) -> crate::Result<()> {
       writeln!(output, "{:?}", backtrace)?;
     }
     output.flush()?;
-    Ok(())
+    std::process::exit(1)
   }
 }