summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorLars Wirzenius <liw@liw.fi>2022-07-17 08:57:02 +0300
committerLars Wirzenius <liw@liw.fi>2022-07-17 08:57:02 +0300
commita4c0a8f693506c1841babe2cd76b4817153b1a03 (patch)
tree704e647321b57110fa880402b4aade60873c1686 /src
parentfd85f4d522fc241851fe2a3cec4458e1e2e35df3 (diff)
downloadroadmap-a4c0a8f693506c1841babe2cd76b4817153b1a03.tar.gz
chore: use clap v3 derive instead of structopt
Sponsored-by: author
Diffstat (limited to 'src')
-rw-r--r--src/bin/roadmap2dot.rs9
1 files changed, 4 insertions, 5 deletions
diff --git a/src/bin/roadmap2dot.rs b/src/bin/roadmap2dot.rs
index 45e73ea..e92f41d 100644
--- a/src/bin/roadmap2dot.rs
+++ b/src/bin/roadmap2dot.rs
@@ -12,22 +12,21 @@
//! crate will be as a library.
use anyhow::Result;
+use clap::Parser;
use roadmap::from_yaml;
use std::fs::File;
use std::io::Read;
use std::path::PathBuf;
-use structopt::StructOpt;
const LABEL_WIDTH: usize = 20;
-#[derive(Debug, StructOpt)]
-#[structopt(
+#[derive(Debug, Parser)]
+#[clap(
name = "roadmap2dot",
about = "Create a dot graph of a roadmap in YAML"
)]
struct Opt {
- // The input filename.
- #[structopt(parse(from_os_str))]
+ /// The input filename.
filename: PathBuf,
}