From ebd8f45653cb72f343b21aa52ec57ca85f50f3d8 Mon Sep 17 00:00:00 2001 From: nozwock <57829219+nozwock@users.noreply.github.com> Date: Sun, 4 Jun 2023 01:47:57 +0530 Subject: [PATCH] Use `visible_alias` instead of hardcoding them in docstrings --- src/main.rs | 26 +++++++++++++------------- 1 file changed, 13 insertions(+), 13 deletions(-) diff --git a/src/main.rs b/src/main.rs index acff0aa..ff016ef 100644 --- a/src/main.rs +++ b/src/main.rs @@ -20,47 +20,47 @@ struct Cli { #[derive(Subcommand)] enum Commands { - /// Authenticate with LeetCode [ -a ] - #[command(alias = "-a")] + /// Authenticate with LeetCode + #[command(visible_alias = "-a")] Auth, - /// Executes code with testcases [ -r ] - #[command(alias = "-rt")] + /// Executes code with testcases + #[command(visible_alias = "-rt")] RunCustom { /// Testcases to run testcases: String, /// File to execute filename: Option, }, - #[command(alias = "-r")] + #[command(visible_alias = "-r")] Run { /// File to execute with default testcases filename: Option, }, - /// Submits code to LeetCode [ -s ] - #[command(alias = "-fs")] + /// Submits code to LeetCode + #[command(visible_alias = "-fs")] FastSubmit { /// File to submit filename: Option, }, - #[command(alias = "-s")] + #[command(visible_alias = "-s")] Submit { /// File to submit filename: Option, }, - /// Save a question as HTML [ -q ] - #[command(alias = "-q")] + /// Save a question as HTML + #[command(visible_alias = "-q")] Question { /// Question name question_name: String, }, - /// Save today's daily challenge as HTML [ -d ] - #[command(alias = "-d")] + /// Save today's daily challenge as HTML + #[command(visible_alias = "-d")] DailyChallenge, } #[derive(Subcommand)] enum Execute { - #[command(alias = "-t")] + #[command(visible_alias = "-t")] Testcases { /// File to run filename: Option,