aboutsummaryrefslogtreecommitdiff
path: root/src/args.rs
diff options
context:
space:
mode:
authorRobin Krahl <robin.krahl@ireas.org>2020-09-29 19:18:56 +0200
committerRobin Krahl <robin.krahl@ireas.org>2020-10-02 11:58:21 +0200
commita6538455de33f6d09dfa4011fbbdaa6e59b132f4 (patch)
tree7f7fcfd2150a56f3c88b2371b63486090e22d207 /src/args.rs
parent458d87d2a7fb31beea3e965bd77d7d0ce25eb4b4 (diff)
downloadnitrocli-nitrokey-v0.8.0.tar.gz
nitrocli-nitrokey-v0.8.0.tar.bz2
Rename numlock, capslock, scrollock optionsnitrokey-v0.8.0
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,