Skip to content

Commit

Permalink
Close console window on first launch if installation is successful
Browse files Browse the repository at this point in the history
  • Loading branch information
TimMisiak committed Jul 9, 2023
1 parent 11ece81 commit 325b48a
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/main.rs
Original file line number Diff line number Diff line change
Expand Up @@ -117,14 +117,14 @@ fn main() {

if let Some(new_version) = new_version {
let version_install_dir = install_dir.join(&new_version);
unsafe { FreeConsole() };
// Now that we're installed, run DbgX.Shell.exe with the given parameters
run_dbgx_shell(&version_install_dir);
} else {
println!("Install failed. Press enter to close this window.");
let mut stdin = std::io::stdin();
let _ = stdin.read(&mut [0u8]).unwrap();
unsafe { FreeConsole() };
}

unsafe { FreeConsole() };
}
}

0 comments on commit 325b48a

Please sign in to comment.