From 0835073d85b7dcf000af71312400820330c3b289 Mon Sep 17 00:00:00 2001 From: JT <547158+jntrnr@users.noreply.github.com> Date: Wed, 9 Mar 2022 08:04:50 -0500 Subject: [PATCH] Adds the proper workarounds for short flags (#4794) --- src/main.rs | 20 ++++++++------------ 1 file changed, 8 insertions(+), 12 deletions(-) diff --git a/src/main.rs b/src/main.rs index fbf163ecdb..4983b83f04 100644 --- a/src/main.rs +++ b/src/main.rs @@ -98,14 +98,10 @@ fn main() -> Result<()> { if arg == "-c" || arg == "--commands" || arg == "--testbin" - || arg == "--develop" - || arg == "--debug" - || arg == "--loglevel" - || arg == "--config" - || arg == "--perf" - || arg == "--threads" - || arg == "--version" || arg == "--log-level" + || arg == "--config" + || arg == "--threads" + || arg == "-t" { collect_arg_nushell = true; } @@ -383,11 +379,6 @@ impl Command for Nu { "run the given commands and then exit", Some('c'), ) - .optional( - "script file", - SyntaxShape::Filepath, - "name of the optional script file to run", - ) .named( "config", SyntaxShape::String, @@ -406,6 +397,11 @@ impl Command for Nu { "threads to use for parallel commands", Some('t'), ) + .optional( + "script file", + SyntaxShape::Filepath, + "name of the optional script file to run", + ) .rest( "script args", SyntaxShape::String,