From 37d304a6f95b8488d45f9adcc0c8742d3b121d2f Mon Sep 17 00:00:00 2001 From: Daniel Silverstone Date: Sat, 14 May 2022 14:20:44 +0100 Subject: (cli): Change from structopt to clap3-derive Signed-off-by: Daniel Silverstone --- src/diagrams.rs | 13 ++++++------- 1 file changed, 6 insertions(+), 7 deletions(-) (limited to 'src/diagrams.rs') diff --git a/src/diagrams.rs b/src/diagrams.rs index 2bdd0ed..6e0b875 100644 --- a/src/diagrams.rs +++ b/src/diagrams.rs @@ -7,29 +7,28 @@ use std::path::PathBuf; use std::process::{Command, Stdio}; use std::sync::Mutex; +use clap::Parser; use lazy_static::lazy_static; -use structopt::StructOpt; - -/// Resources used to configure paths for dot, plantuml.jar, and friends +// Resources used to configure paths for dot, plantuml.jar, and friends #[allow(missing_docs)] -#[derive(Debug, StructOpt)] +#[derive(Debug, Parser)] pub struct MarkupOpts { - #[structopt( + #[clap( long = "dot", help = "Path to the `dot` binary.", name = "DOTPATH", env = "SUBPLOT_DOT_PATH" )] dot_path: Option, - #[structopt( + #[clap( long = "plantuml-jar", help = "Path to the `plantuml.jar` file.", name = "PLANTUMLJARPATH", env = "SUBPLOT_PLANTUML_JAR_PATH" )] plantuml_jar_path: Option, - #[structopt( + #[clap( long = "java", help = "Path to Java executable (note, effectively overrides JAVA_HOME if set to an absolute path)", name = "JAVA_PATH", -- cgit v1.2.1