Compare commits
No commits in common. "ad7fc4e0cd18fa623d5727dae9480b43cd1bb593" and "9bac43bf5d4a9a0b8ac1430da65181fd59d4fd44" have entirely different histories.
ad7fc4e0cd
...
9bac43bf5d
3 changed files with 2 additions and 15 deletions
|
@ -20,7 +20,7 @@ path = "src/main.rs"
|
||||||
|
|
||||||
[dependencies]
|
[dependencies]
|
||||||
pico-args = "0.5.0"
|
pico-args = "0.5.0"
|
||||||
termion = "4.0.3"
|
termion = "3.0.0"
|
||||||
|
|
||||||
[profile.release]
|
[profile.release]
|
||||||
opt-level = 's'
|
opt-level = 's'
|
||||||
|
|
|
@ -82,13 +82,6 @@ The rainbow flag designed for 2017 Philadelphia Pride.
|
||||||
.It Ic transgender, trans
|
.It Ic transgender, trans
|
||||||
The transgender pride flag designed by Monica Helms in 1999.
|
The transgender pride flag designed by Monica Helms in 1999.
|
||||||
.El
|
.El
|
||||||
.Sh ENVIRONMENT
|
|
||||||
.Bl -tag -width Ds
|
|
||||||
.It PRIDE_DEFAULT
|
|
||||||
A string containing the name of a flag to use as the default when no
|
|
||||||
.Ar flag
|
|
||||||
argument is provided.
|
|
||||||
.El
|
|
||||||
.Sh EXIT STATUS
|
.Sh EXIT STATUS
|
||||||
.Bl -tag -width Ds
|
.Bl -tag -width Ds
|
||||||
.It 1
|
.It 1
|
||||||
|
|
|
@ -1,5 +1,4 @@
|
||||||
//! main method module
|
//! main method module
|
||||||
use std::env::var;
|
|
||||||
|
|
||||||
use pico_args::Arguments;
|
use pico_args::Arguments;
|
||||||
|
|
||||||
|
@ -51,12 +50,7 @@ fn main() {
|
||||||
|
|
||||||
let state = State::new(&mut args);
|
let state = State::new(&mut args);
|
||||||
|
|
||||||
let subcommand =
|
let subcommand = args.subcommand().unwrap();
|
||||||
if let Ok(Some(subcommand)) = args.subcommand() { Some(subcommand) }
|
|
||||||
else if let Ok(default) = var("PRIDE_DEFAULT") {
|
|
||||||
if default.is_empty() { None }
|
|
||||||
else { Some(default) }
|
|
||||||
} else { None };
|
|
||||||
let variant = args.subcommand().unwrap();
|
let variant = args.subcommand().unwrap();
|
||||||
|
|
||||||
// get color vec from matched flag
|
// get color vec from matched flag
|
||||||
|
|
Loading…
Reference in a new issue