aboutsummaryrefslogtreecommitdiff
path: root/src/args.rs
diff options
context:
space:
mode:
authorRobin Krahl <robin.krahl@ireas.org>2020-09-29 19:18:56 +0200
committerDaniel Mueller <deso@posteo.net>2020-10-11 16:26:54 -0700
commitaaf0286994fcffa8dc81a2569ad70ec6fd7c9b90 (patch)
tree00b8e65562302ab7148c5659708578b3bfb42c6f /src/args.rs
parent6be92c8425dd5285c16a1722aa95683ea146cf46 (diff)
downloadnitrocli-aaf0286994fcffa8dc81a2569ad70ec6fd7c9b90.tar.gz
nitrocli-aaf0286994fcffa8dc81a2569ad70ec6fd7c9b90.tar.bz2
Rename numlock, capslock, scrollock options
This patch renames the options for the config set command: --numlock ==> --num-lock --capslock ==> --caps-lock --scrolllock ==> --scroll-lock --no-numlock ==> --no-num-lock --no-capslock ==> --no-caps-lock --no-scrolllock ==> --no-scroll-lock The original naming was based on a typo in nitrokey-rs (scrollock vs. scrolllock). Also, the typical spelling for the keys is Num Lock, Caps Lock and Scroll Lock, so using a hyphen is a more natural.
Diffstat (limited to 'src/args.rs')
-rw-r--r--src/args.rs30
1 files changed, 15 insertions, 15 deletions
diff --git a/src/args.rs b/src/args.rs
index a38ca6a..6cf37c8 100644
--- a/src/args.rs
+++ b/src/args.rs
@@ -125,24 +125,24 @@ Command! {ConfigCommand, [
#[derive(Debug, PartialEq, structopt::StructOpt)]
pub struct ConfigSetArgs {
- /// Sets the numlock option to the given HOTP slot
+ /// Sets the Num Lock option to the given HOTP slot
#[structopt(short = "n", long)]
- pub numlock: Option<u8>,
- /// Unsets the numlock option
- #[structopt(short = "N", long, conflicts_with("numlock"))]
- pub no_numlock: bool,
- /// Sets the capslock option to the given HOTP slot
+ pub num_lock: Option<u8>,
+ /// Unsets the Num Lock option
+ #[structopt(short = "N", long, conflicts_with("num-lock"))]
+ pub no_num_lock: bool,
+ /// Sets the Cap Lock option to the given HOTP slot
#[structopt(short = "c", long)]
- pub capslock: Option<u8>,
- /// Unsets the capslock option
- #[structopt(short = "C", long, conflicts_with("capslock"))]
- pub no_capslock: bool,
- /// Sets the scrollock option to the given HOTP slot
+ pub caps_lock: Option<u8>,
+ /// Unsets the Caps Lock option
+ #[structopt(short = "C", long, conflicts_with("caps-lock"))]
+ pub no_caps_lock: bool,
+ /// Sets the Scroll Lock option to the given HOTP slot
#[structopt(short = "s", long)]
- pub scrollock: Option<u8>,
- /// Unsets the scrollock option
- #[structopt(short = "S", long, conflicts_with("scrollock"))]
- pub no_scrollock: bool,
+ pub scroll_lock: Option<u8>,
+ /// Unsets the Scroll Lock option
+ #[structopt(short = "S", long, conflicts_with("scroll-lock"))]
+ pub no_scroll_lock: bool,
/// Requires the user PIN to generate one-time passwords
#[structopt(short = "o", long)]
pub otp_pin: bool,