From 949c6459aa7683453a7160423b689ceadb08954b Mon Sep 17 00:00:00 2001 From: DanConwayDev Date: Wed, 4 Sep 2024 08:04:48 +0100 Subject: refactor: organise into lib and bin structure the make the code more readable this commit just moves the files, the next commit should fix the imports --- src/main.rs | 32 -------------------------------- 1 file changed, 32 deletions(-) delete mode 100644 src/main.rs (limited to 'src/main.rs') diff --git a/src/main.rs b/src/main.rs deleted file mode 100644 index e833e4a..0000000 --- a/src/main.rs +++ /dev/null @@ -1,32 +0,0 @@ -#![cfg_attr(not(test), warn(clippy::pedantic))] -#![allow(clippy::large_futures)] -#![cfg_attr(not(test), warn(clippy::expect_used))] - -use anyhow::Result; -use clap::Parser; -use cli::{Cli, Commands}; - -mod cli; -mod cli_interactor; -mod client; -mod config; -mod git; -mod key_handling; -mod login; -mod repo_ref; -mod repo_state; -mod sub_commands; - -#[tokio::main] -async fn main() -> Result<()> { - let cli = Cli::parse(); - match &cli.command { - Commands::Fetch(args) => sub_commands::fetch::launch(&cli, args).await, - Commands::Login(args) => sub_commands::login::launch(&cli, args).await, - Commands::Init(args) => sub_commands::init::launch(&cli, args).await, - Commands::Send(args) => sub_commands::send::launch(&cli, args, false).await, - Commands::List => sub_commands::list::launch().await, - Commands::Pull => sub_commands::pull::launch().await, - Commands::Push(args) => sub_commands::push::launch(&cli, args).await, - } -} -- cgit v1.2.3