From 9e0d9de1e1be3daee559fb773e0f94bdc7c5c655 Mon Sep 17 00:00:00 2001 From: "E. Almqvist" Date: Thu, 11 Aug 2022 00:33:32 +0200 Subject: [PATCH] Formatting --- src/cli.rs | 24 ++++++++++++++++++++---- src/main.rs | 2 +- 2 files changed, 21 insertions(+), 5 deletions(-) diff --git a/src/cli.rs b/src/cli.rs index dd448e6..e3e63d4 100644 --- a/src/cli.rs +++ b/src/cli.rs @@ -7,12 +7,28 @@ pub struct Args { #[clap(help = "Which port to scan for.", short = 'p', long = "port")] pub port: u16, - #[clap(help = "Amount of threads that will be used when scanning for the specified port.", short = 'n', long = "threads", default_value_t = 1)] + #[clap( + help = "Amount of threads that will be used when scanning for the specified port.", + short = 'n', + long = "threads", + default_value_t = 1 + )] pub threads: u8, - #[clap(help = "A file containing ignored IPv4 addresses (seperated by linebreaks).", short = 'i', long = "ignore-ip-list", default_value = "ignore-ips-list.txt")] + #[clap( + help = "A file containing ignored IPv4 addresses (seperated by linebreaks).", + short = 'i', + long = "ignore-ip-list", + default_value = "ignore-ips-list.txt" + )] pub ignorelist: PathBuf, - #[clap(help = "Enable verbose (debug) output", short = 'v', long = "verbose", takes_value = false, required = false)] - pub verbose: bool + #[clap( + help = "Enable verbose (debug) output", + short = 'v', + long = "verbose", + takes_value = false, + required = false + )] + pub verbose: bool, } diff --git a/src/main.rs b/src/main.rs index db65208..eb1fb10 100644 --- a/src/main.rs +++ b/src/main.rs @@ -1,7 +1,7 @@ +mod cli; mod ipv4; mod scanner; mod util; -mod cli; use clap::Parser; use cli::Args;