login to start
This commit is contained in:
10
src/main.rs
10
src/main.rs
@ -6,7 +6,7 @@
|
||||
/* By: tomoron <tomoron@student.42angouleme.fr> +#+ +:+ +#+ */
|
||||
/* +#+#+#+#+#+ +#+ */
|
||||
/* Created: 2026/05/29 21:22:17 by tomoron #+# #+# */
|
||||
/* Updated: 2026/06/09 17:04:32 by tomoron ### ########.fr */
|
||||
/* Updated: 2026/06/10 13:16:50 by tomoron ### ########.fr */
|
||||
/* */
|
||||
/* ************************************************************************** */
|
||||
|
||||
@ -74,14 +74,14 @@ async fn main() -> Result<(), String> {
|
||||
let docker = Docker::connect_with_defaults().expect("Failed to connect to local docker");
|
||||
|
||||
match arg.subcommand() {
|
||||
Some(("serverMode", _)) => { mc_socket_listen(pool).await.map_err(|_| "socket error".to_string())?; },
|
||||
Some(("serverMode", _)) => { mc_socket_listen(pool, docker).await.map_err(|_| "socket error".to_string())?; },
|
||||
Some(("add", sub_matches)) => { add::subcommand(sub_matches, pool).await?; },
|
||||
Some(("remove", sub_matches)) => { remove::subcommand(sub_matches, pool).await?; },
|
||||
Some(("remove", sub_matches)) => { remove::subcommand(sub_matches, &pool, &docker).await?; },
|
||||
Some(("ls", sub_matches)) => { ls::subcommand(sub_matches, pool).await?; },
|
||||
Some(("edit", sub_matches)) => { edit::subcommand(sub_matches, pool).await?; },
|
||||
|
||||
Some(("start", sub_matches)) => { start::subcommand(sub_matches, &pool, docker).await?; },
|
||||
Some(("stop", sub_matches)) => { stop::subcommand(sub_matches, &pool, docker).await?; },
|
||||
Some(("start", sub_matches)) => { start::subcommand(sub_matches, &pool, &docker).await?; },
|
||||
Some(("stop", sub_matches)) => { stop::subcommand(sub_matches, &pool, &docker).await?; },
|
||||
_ => {panic!("subcommand not implemented")}
|
||||
}
|
||||
Ok(())
|
||||
|
||||
Reference in New Issue
Block a user