mirror of
https://forgejo.ellis.link/continuwuation/continuwuity.git
synced 2025-06-26 22:56:37 +02:00
20 lines
486 B
Rust
20 lines
486 B
Rust
//! Integration with `clap`
|
|
|
|
use std::path::PathBuf;
|
|
|
|
use clap::Parser;
|
|
|
|
use super::conduwuit_version;
|
|
|
|
/// Commandline arguments
|
|
#[derive(Parser, Debug)]
|
|
#[clap(version = conduwuit_version(), about, long_about = None)]
|
|
pub(crate) struct Args {
|
|
#[arg(short, long)]
|
|
/// Optional argument to the path of a conduwuit config TOML file
|
|
pub(crate) config: Option<PathBuf>,
|
|
}
|
|
|
|
/// Parse commandline arguments into structured data
|
|
#[must_use]
|
|
pub(crate) fn parse() -> Args { Args::parse() }
|