Skip to content

Commit

Permalink
fix: required commands
Browse files Browse the repository at this point in the history
  • Loading branch information
tofuuudon committed Oct 21, 2024
1 parent 9da7093 commit b5b8a0f
Showing 1 changed file with 5 additions and 7 deletions.
12 changes: 5 additions & 7 deletions src/main.rs
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ mod modules;
#[derive(Parser)]
struct Cli {
#[command(subcommand)]
command: Option<Commands>,
command: Commands,
}

#[derive(Subcommand)]
Expand All @@ -32,21 +32,21 @@ enum Platform {
enum Commands {
Migrate {
#[command(subcommand)]
platform: Option<Platform>,
platform: Platform,
},
}

fn main() {
let cli = Cli::parse();

match &cli.command {
Some(Commands::Migrate { platform }) => match platform {
Some(Platform::GitHub {
Commands::Migrate { platform } => match platform {
Platform::GitHub {
create_repo,
org,
repo_name,
reset,
}) => {
} => {
let url = format!("[email protected]:{}/{}.git", org, repo_name);
let config = Config::open_default().unwrap();
let user = config
Expand Down Expand Up @@ -86,8 +86,6 @@ fn main() {
Err(e) => println!("Failed to push: {}", e),
}
}
None => {}
},
None => {}
}
}

0 comments on commit b5b8a0f

Please sign in to comment.