mirror of
https://github.com/YGGverse/aquatic-crawler.git
synced 2026-04-01 01:25:36 +00:00
initial commit
This commit is contained in:
parent
9fcd892d42
commit
d55c642eb6
11 changed files with 305 additions and 1 deletions
26
src/argument.rs
Normal file
26
src/argument.rs
Normal file
|
|
@ -0,0 +1,26 @@
|
|||
use clap::Parser;
|
||||
|
||||
#[derive(Parser, Debug)]
|
||||
#[command(version, about, long_about = None)]
|
||||
pub struct Argument {
|
||||
/// Debug level
|
||||
///
|
||||
/// * `e` - error
|
||||
/// * `i` - info
|
||||
#[arg(short, long, default_value_t = String::from("ei"))]
|
||||
pub debug: String,
|
||||
|
||||
/// Filepath(s) to the Aquatic tracker info-hash JSON/API
|
||||
///
|
||||
/// * PR #233 info-hash table implementation has multiple source tables for IPv4 and IPv6
|
||||
#[arg(short, long)]
|
||||
pub infohash_source: Vec<String>,
|
||||
|
||||
/// Directory path to store the `.torrent` files
|
||||
#[arg(short, long)]
|
||||
pub torrents_path: Option<String>,
|
||||
|
||||
/// Crawl loop delay in seconds
|
||||
#[arg(short, long, default_value_t = 300)]
|
||||
pub sleep: u64,
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue