mirror of
				https://github.com/WarrenHood/MCModpackManager.git
				synced 2025-11-04 12:58:41 +00:00 
			
		
		
		
	Compare commits
	
		
			2 commits
		
	
	
		
			6239bb9fd8
			...
			042bfb8baa
		
	
	| Author | SHA1 | Date | |
|---|---|---|---|
| 
							
							
								
								 | 
						042bfb8baa | ||
| 
							
							
								
								 | 
						05cfb761a9 | 
| 
						 | 
					@ -72,6 +72,9 @@ enum Commands {
 | 
				
			||||||
        /// Modloader override
 | 
					        /// Modloader override
 | 
				
			||||||
        #[arg(long, short)]
 | 
					        #[arg(long, short)]
 | 
				
			||||||
        modloader: Option<modpack::ModLoader>,
 | 
					        modloader: Option<modpack::ModLoader>,
 | 
				
			||||||
 | 
					        /// Side override
 | 
				
			||||||
 | 
					        #[arg(long, short)]
 | 
				
			||||||
 | 
					        side: Option<DownloadSide>
 | 
				
			||||||
    },
 | 
					    },
 | 
				
			||||||
    /// Remove a mod from the modpack
 | 
					    /// Remove a mod from the modpack
 | 
				
			||||||
    Remove {
 | 
					    Remove {
 | 
				
			||||||
| 
						 | 
					@ -225,6 +228,7 @@ async fn main() -> anyhow::Result<()> {
 | 
				
			||||||
                locked,
 | 
					                locked,
 | 
				
			||||||
                mc_version,
 | 
					                mc_version,
 | 
				
			||||||
                modloader,
 | 
					                modloader,
 | 
				
			||||||
 | 
					                side
 | 
				
			||||||
            } => {
 | 
					            } => {
 | 
				
			||||||
                let mut modpack_meta = ModpackMeta::load_from_current_directory()?;
 | 
					                let mut modpack_meta = ModpackMeta::load_from_current_directory()?;
 | 
				
			||||||
                let old_modpack_meta = modpack_meta.clone();
 | 
					                let old_modpack_meta = modpack_meta.clone();
 | 
				
			||||||
| 
						 | 
					@ -242,6 +246,22 @@ async fn main() -> anyhow::Result<()> {
 | 
				
			||||||
                if let Some(url) = url {
 | 
					                if let Some(url) = url {
 | 
				
			||||||
                    mod_meta = mod_meta.url(&url);
 | 
					                    mod_meta = mod_meta.url(&url);
 | 
				
			||||||
                }
 | 
					                }
 | 
				
			||||||
 | 
					                if let Some(side) = side {
 | 
				
			||||||
 | 
					                    match side {
 | 
				
			||||||
 | 
					                        DownloadSide::Both => {
 | 
				
			||||||
 | 
					                            mod_meta.server_side = Some(true);
 | 
				
			||||||
 | 
					                            mod_meta.client_side = Some(true);
 | 
				
			||||||
 | 
					                        },
 | 
				
			||||||
 | 
					                        DownloadSide::Server => {
 | 
				
			||||||
 | 
					                            mod_meta.server_side = Some(true);
 | 
				
			||||||
 | 
					                            mod_meta.client_side = Some(false);
 | 
				
			||||||
 | 
					                        },
 | 
				
			||||||
 | 
					                        DownloadSide::Client => {
 | 
				
			||||||
 | 
					                            mod_meta.server_side = Some(false);
 | 
				
			||||||
 | 
					                            mod_meta.client_side = Some(true);
 | 
				
			||||||
 | 
					                        },
 | 
				
			||||||
 | 
					                    }
 | 
				
			||||||
 | 
					                }
 | 
				
			||||||
                for provider in providers.into_iter() {
 | 
					                for provider in providers.into_iter() {
 | 
				
			||||||
                    mod_meta = mod_meta.provider(provider);
 | 
					                    mod_meta = mod_meta.provider(provider);
 | 
				
			||||||
                }
 | 
					                }
 | 
				
			||||||
| 
						 | 
					
 | 
				
			||||||
| 
						 | 
					@ -198,8 +198,12 @@ impl Modrinth {
 | 
				
			||||||
            } else {
 | 
					            } else {
 | 
				
			||||||
                None
 | 
					                None
 | 
				
			||||||
            },
 | 
					            },
 | 
				
			||||||
            server_side: project.server_side != "unsupported",
 | 
					            server_side: mod_meta
 | 
				
			||||||
            client_side: project.client_side != "unsupported",
 | 
					                .server_side
 | 
				
			||||||
 | 
					                .unwrap_or(project.server_side != "unsupported"),
 | 
				
			||||||
 | 
					            client_side: mod_meta
 | 
				
			||||||
 | 
					                .client_side
 | 
				
			||||||
 | 
					                .unwrap_or(project.client_side != "unsupported"),
 | 
				
			||||||
        })
 | 
					        })
 | 
				
			||||||
    }
 | 
					    }
 | 
				
			||||||
 | 
					
 | 
				
			||||||
| 
						 | 
					
 | 
				
			||||||
| 
						 | 
					@ -134,6 +134,7 @@ impl Application for ManagerGUI {
 | 
				
			||||||
    fn update(&mut self, message: Message) -> Command<Message> {
 | 
					    fn update(&mut self, message: Message) -> Command<Message> {
 | 
				
			||||||
        match message {
 | 
					        match message {
 | 
				
			||||||
            Message::SwitchView(view) => {
 | 
					            Message::SwitchView(view) => {
 | 
				
			||||||
 | 
					                self.current_install_status = ProfileInstallStatus::NotStarted;
 | 
				
			||||||
                match &view {
 | 
					                match &view {
 | 
				
			||||||
                    ManagerView::AddProfile => {
 | 
					                    ManagerView::AddProfile => {
 | 
				
			||||||
                        self.profile_save_error = None;
 | 
					                        self.profile_save_error = None;
 | 
				
			||||||
| 
						 | 
					
 | 
				
			||||||
		Loading…
	
		Reference in a new issue