mirror of
https://github.com/velopack/velopack.git
synced 2025-10-25 15:19:22 +00:00
Fix windows rust build
This commit is contained in:
@@ -6,6 +6,7 @@ mod logging;
|
|||||||
extern crate log;
|
extern crate log;
|
||||||
|
|
||||||
use std::{
|
use std::{
|
||||||
|
env,
|
||||||
os::windows::process::CommandExt,
|
os::windows::process::CommandExt,
|
||||||
process::{Command as Process, ExitCode},
|
process::{Command as Process, ExitCode},
|
||||||
};
|
};
|
||||||
@@ -14,7 +15,13 @@ fn main() -> ExitCode {
|
|||||||
let my_path = std::env::current_exe().unwrap();
|
let my_path = std::env::current_exe().unwrap();
|
||||||
let my_name = my_path.file_name().unwrap().to_string_lossy();
|
let my_name = my_path.file_name().unwrap().to_string_lossy();
|
||||||
|
|
||||||
let _ = logging::default_logging(false, false);
|
let default_log_file = {
|
||||||
|
let mut my_dir = env::current_exe().unwrap();
|
||||||
|
my_dir.pop();
|
||||||
|
my_dir.join("Velopack.log")
|
||||||
|
};
|
||||||
|
|
||||||
|
let _ = logging::setup_logging(Some(&default_log_file), false, false, false);
|
||||||
|
|
||||||
let mut update_exe = my_path.clone();
|
let mut update_exe = my_path.clone();
|
||||||
update_exe.pop();
|
update_exe.pop();
|
||||||
|
|||||||
Reference in New Issue
Block a user