2020Support
This commit is contained in:
parent
966252d99f
commit
35b9172a6a
|
|
@ -1261,7 +1261,7 @@ dependencies = [
|
||||||
|
|
||||||
[[package]]
|
[[package]]
|
||||||
name = "syntax_bootstrapper"
|
name = "syntax_bootstrapper"
|
||||||
version = "1.1.3"
|
version = "1.2.0"
|
||||||
dependencies = [
|
dependencies = [
|
||||||
"chrono",
|
"chrono",
|
||||||
"colored",
|
"colored",
|
||||||
|
|
|
||||||
|
|
@ -1,6 +1,6 @@
|
||||||
[package]
|
[package]
|
||||||
name = "syntax_bootstrapper"
|
name = "syntax_bootstrapper"
|
||||||
version = "1.1.3"
|
version = "1.2.0"
|
||||||
edition = "2021"
|
edition = "2021"
|
||||||
|
|
||||||
# See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html
|
# See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html
|
||||||
|
|
|
||||||
|
|
@ -305,6 +305,7 @@ async fn main() {
|
||||||
let ShadersZip : PathBuf = download_file_prefix(&http_client, format!("{}shaders.zip", VersionURLPrefix).as_str(), &temp_downloads_directory).await;
|
let ShadersZip : PathBuf = download_file_prefix(&http_client, format!("{}shaders.zip", VersionURLPrefix).as_str(), &temp_downloads_directory).await;
|
||||||
|
|
||||||
let Client2018Zip : PathBuf = download_file_prefix(&http_client, format!("{}2018client.zip", VersionURLPrefix).as_str(), &temp_downloads_directory).await;
|
let Client2018Zip : PathBuf = download_file_prefix(&http_client, format!("{}2018client.zip", VersionURLPrefix).as_str(), &temp_downloads_directory).await;
|
||||||
|
let Client2020Zip : PathBuf = download_file_prefix(&http_client, format!("{}2020client.zip", VersionURLPrefix).as_str(), &temp_downloads_directory).await;
|
||||||
info("Download finished, extracting files.");
|
info("Download finished, extracting files.");
|
||||||
|
|
||||||
fn extract_to_dir( zip_file : &PathBuf, target_dir : &PathBuf ) {
|
fn extract_to_dir( zip_file : &PathBuf, target_dir : &PathBuf ) {
|
||||||
|
|
@ -364,6 +365,10 @@ async fn main() {
|
||||||
create_folder_if_not_exists(&client_2018_directory).await;
|
create_folder_if_not_exists(&client_2018_directory).await;
|
||||||
extract_to_dir(&Client2018Zip, &client_2018_directory);
|
extract_to_dir(&Client2018Zip, &client_2018_directory);
|
||||||
|
|
||||||
|
let client_2020_directory = current_version_directory.join("Client2020");
|
||||||
|
create_folder_if_not_exists(&client_2020_directory).await;
|
||||||
|
extract_to_dir(&Client2020Zip, &client_2020_directory);
|
||||||
|
|
||||||
info("Finished extracting files, cleaning up.");
|
info("Finished extracting files, cleaning up.");
|
||||||
std::fs::remove_dir_all(&temp_downloads_directory).unwrap();
|
std::fs::remove_dir_all(&temp_downloads_directory).unwrap();
|
||||||
|
|
||||||
|
|
@ -509,6 +514,8 @@ x-scheme-handler/syntax-player=syntax-player.desktop
|
||||||
debug(&client_year.to_string());
|
debug(&client_year.to_string());
|
||||||
if client_year == "2018" {
|
if client_year == "2018" {
|
||||||
client_executable_path = current_version_directory.join("Client2018").join("SyntaxPlayerBeta.exe");
|
client_executable_path = current_version_directory.join("Client2018").join("SyntaxPlayerBeta.exe");
|
||||||
|
} else if client_year == "2020" {
|
||||||
|
client_executable_path = current_version_directory.join("Client2020").join("SyntaxPlayerBeta.exe");
|
||||||
} else {
|
} else {
|
||||||
client_executable_path = current_version_directory.join("SyntaxPlayerBeta.exe");
|
client_executable_path = current_version_directory.join("SyntaxPlayerBeta.exe");
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue