Skip to content

Commit 210c02b

Browse files
committed
Fix dotnet new help to include argument names
1 parent 9acd4b3 commit 210c02b

File tree

1 file changed

+6
-6
lines changed

1 file changed

+6
-6
lines changed

src/Cli/dotnet/Parser.cs

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -315,6 +315,12 @@ public override void Write(HelpContext context)
315315
return;
316316
}
317317

318+
// argument/option cleanups specific to help
319+
foreach (var option in command.Options)
320+
{
321+
option.EnsureHelpName();
322+
}
323+
318324
if (command.Equals(NuGetCommandParser.GetCommand()) || command.Parents.Any(parent => parent == NuGetCommandParser.GetCommand()))
319325
{
320326
NuGetCommand.Run(context.ParseResult);
@@ -356,12 +362,6 @@ public override void Write(HelpContext context)
356362
}
357363
else
358364
{
359-
// argument/option cleanups specific to help
360-
foreach (var option in command.Options)
361-
{
362-
option.EnsureHelpName();
363-
}
364-
365365
if (command.Name.Equals(ListReferenceCommandParser.GetCommand().Name))
366366
{
367367
Command listCommand = command.Parents.Single() as Command;

0 commit comments

Comments
 (0)