|
@@ -361,7 +361,16 @@ fn run_candle(
|
|
|
.current_dir(build_path);
|
|
|
|
|
|
common::print_info("running candle.exe")?;
|
|
|
- common::execute_with_output(&mut cmd).map_err(|_| crate::Error::CandleError)
|
|
|
+ common::execute_with_verbosity(&mut cmd, &settings).map_err(|_| {
|
|
|
+ crate::Error::ShellScriptError(format!(
|
|
|
+ "error running candle.exe{}",
|
|
|
+ if settings.is_verbose() {
|
|
|
+ ""
|
|
|
+ } else {
|
|
|
+ ", try running with --verbose to see command output"
|
|
|
+ }
|
|
|
+ ))
|
|
|
+ })
|
|
|
}
|
|
|
|
|
|
/// Runs the Light.exe file. Light takes the generated code from Candle and produces an MSI Installer.
|
|
@@ -370,6 +379,7 @@ fn run_light(
|
|
|
build_path: &Path,
|
|
|
wixobjs: &[&str],
|
|
|
output_path: &Path,
|
|
|
+ settings: &Settings,
|
|
|
) -> crate::Result<PathBuf> {
|
|
|
let light_exe = wix_toolset_path.join("light.exe");
|
|
|
|
|
@@ -391,9 +401,18 @@ fn run_light(
|
|
|
.current_dir(build_path);
|
|
|
|
|
|
common::print_info(format!("running light to produce {}", output_path.display()).as_str())?;
|
|
|
- common::execute_with_output(&mut cmd)
|
|
|
+ common::execute_with_verbosity(&mut cmd, &settings)
|
|
|
.map(|_| output_path.to_path_buf())
|
|
|
- .map_err(|_| crate::Error::LightError)
|
|
|
+ .map_err(|_| {
|
|
|
+ crate::Error::ShellScriptError(format!(
|
|
|
+ "error running light.exe{}",
|
|
|
+ if settings.is_verbose() {
|
|
|
+ ""
|
|
|
+ } else {
|
|
|
+ ", try running with --verbose to see command output"
|
|
|
+ }
|
|
|
+ ))
|
|
|
+ })
|
|
|
}
|
|
|
|
|
|
// fn get_icon_data() -> crate::Result<()> {
|
|
@@ -512,7 +531,8 @@ pub fn build_wix_app_installer(
|
|
|
&wix_toolset_path,
|
|
|
&output_path,
|
|
|
&wixobjs,
|
|
|
- &app_installer_dir(settings)?,
|
|
|
+ &app_installer_dir(&settings)?,
|
|
|
+ &settings,
|
|
|
)?;
|
|
|
|
|
|
Ok(target)
|