You've already forked AstralRinth
forked from didirus/AstralRinth
Performance improvements (#114)
* Performance improvements * run fmt * optimize creation modal * remove print, fix mod loader editing * Fix library update * update extract loading bar * Update theseus_gui/src-tauri/src/api/metadata.rs Co-authored-by: triphora <emma@modrinth.com> * fix cli --------- Co-authored-by: triphora <emma@modrinth.com>
This commit is contained in:
@@ -61,7 +61,7 @@ async fn main() -> theseus::Result<()> {
|
||||
// Clear profiles
|
||||
println!("Clearing profiles.");
|
||||
{
|
||||
let h = profile::list().await?;
|
||||
let h = profile::list(None).await?;
|
||||
for (path, _) in h.into_iter() {
|
||||
profile::remove(&path).await?;
|
||||
}
|
||||
@@ -69,51 +69,52 @@ async fn main() -> theseus::Result<()> {
|
||||
|
||||
println!("Creating/adding profile.");
|
||||
|
||||
let name = "Example".to_string();
|
||||
let game_version = "1.19.2".to_string();
|
||||
let modloader = ModLoader::Vanilla;
|
||||
let loader_version = "stable".to_string();
|
||||
|
||||
let profile_path = profile_create(
|
||||
name.clone(),
|
||||
game_version,
|
||||
modloader,
|
||||
Some(loader_version),
|
||||
None,
|
||||
None,
|
||||
None,
|
||||
None,
|
||||
)
|
||||
.await?;
|
||||
|
||||
install(&profile_path).await.unwrap();
|
||||
// let name = "Example".to_string();
|
||||
// let game_version = "1.19.2".to_string();
|
||||
// let modloader = ModLoader::Vanilla;
|
||||
// let loader_version = "stable".to_string();
|
||||
//
|
||||
// let profile_path = profile_create(
|
||||
// name.clone(),
|
||||
// game_version,
|
||||
// modloader,
|
||||
// Some(loader_version),
|
||||
// None,
|
||||
// None,
|
||||
// None,
|
||||
// None,
|
||||
// )
|
||||
// .await?;
|
||||
//
|
||||
// install(&profile_path).await.unwrap();
|
||||
|
||||
// let mut value = list().await?;
|
||||
// let profile_path = value.iter().next().map(|x| x.0).unwrap();
|
||||
|
||||
println!("Adding sodium");
|
||||
let sodium_path = profile::add_project_from_version(
|
||||
&profile_path,
|
||||
"rAfhHfow".to_string(),
|
||||
)
|
||||
.await?;
|
||||
|
||||
let mod_menu_path = profile::add_project_from_version(
|
||||
&profile_path,
|
||||
"gSoPJyVn".to_string(),
|
||||
)
|
||||
.await?;
|
||||
|
||||
println!("Disabling sodium");
|
||||
profile::toggle_disable_project(&profile_path, &sodium_path).await?;
|
||||
// println!("Adding sodium");
|
||||
// let sodium_path = profile::add_project_from_version(
|
||||
// &profile_path,
|
||||
// "rAfhHfow".to_string(),
|
||||
// )
|
||||
// .await?;
|
||||
//
|
||||
// let mod_menu_path = profile::add_project_from_version(
|
||||
// &profile_path,
|
||||
// "gSoPJyVn".to_string(),
|
||||
// )
|
||||
// .await?;
|
||||
//
|
||||
// println!("Disabling sodium");
|
||||
// profile::toggle_disable_project(&profile_path, &sodium_path).await?;
|
||||
|
||||
// profile::remove_project(&profile_path, &mod_menu_path).await?;
|
||||
// let profile_path = pack::install_pack_from_version_id(
|
||||
// "zroFQG1k".to_string(),
|
||||
// Some("Technical Electrical".to_string()),
|
||||
// )
|
||||
// .await
|
||||
// .unwrap();
|
||||
let profile_path = pack::install_pack_from_version_id(
|
||||
"CeeCkHke".to_string(),
|
||||
"Technical Electrical".to_string(),
|
||||
None,
|
||||
)
|
||||
.await
|
||||
.unwrap();
|
||||
|
||||
// async closure for testing any desired edits
|
||||
// (ie: changing the java runtime of an added profile)
|
||||
|
||||
Reference in New Issue
Block a user