feat(bundler) bail if can't parse tauri config (#502)

This commit is contained in:
Lucas Fernandes Nogueira 2020-03-09 17:57:57 -03:00 committed by GitHub
parent d37efa5605
commit 7278061e44
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -243,7 +243,13 @@ impl Settings {
let merged_bundle_settings = match tauri_config {
Ok(config) => merge_settings(bundle_settings, config.tauri.bundle),
Err(_) => bundle_settings,
Err(e) => {
let error_message = e.to_string();
if !error_message.contains("No such file or directory") {
bail!("Failed to read Tauri config: {}", error_message);
}
bundle_settings
},
};
Ok(Settings {