fix unix self_update::run
This commit is contained in:
parent
c93fcba652
commit
99010664bf
@ -13,15 +13,15 @@ pub async fn self_update_available() -> bool {
|
|||||||
}
|
}
|
||||||
|
|
||||||
#[cfg(not(windows))]
|
#[cfg(not(windows))]
|
||||||
pub fn run(_update_only: bool) {
|
pub async fn run(_update_only: bool) {
|
||||||
if self_update_available() {
|
if self_update_available().await {
|
||||||
println!("A new version of the AlterWare launcher is available.");
|
println!("A new version of the AlterWare launcher is available.");
|
||||||
println!(
|
println!(
|
||||||
"Download it at {}",
|
"Download it at {}",
|
||||||
github::latest_release_url(GH_OWNER, GH_REPO)
|
github::latest_release_url(GH_OWNER, GH_REPO)
|
||||||
);
|
);
|
||||||
println!("Launching in 10 seconds..");
|
println!("Launching in 10 seconds..");
|
||||||
thread::sleep(time::Duration::from_secs(10));
|
tokio::time::sleep(tokio::time::Duration::from_secs(10)).await;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user