-
Notifications
You must be signed in to change notification settings - Fork 8
Expand file tree
/
Copy pathProgram.cs
More file actions
20 lines (18 loc) · 832 Bytes
/
Program.cs
File metadata and controls
20 lines (18 loc) · 832 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
using NestedCommands;
using Ookii.CommandLine;
using Ookii.CommandLine.Commands;
var options = new CommandOptions()
{
UsageWriter = new UsageWriter()
{
// Add the application description.
IncludeApplicationDescriptionBeforeCommandList = true,
// The commands that derive from ParentCommand use ICommandWithCustomParsing, and don't
// technically have a -Help argument. This prevents the instruction from being shown by
// default. However, these commands will ignore -Help ignore it and print their child
// command list anyway, so force the message to be shown.
IncludeCommandHelpInstruction = TriState.True,
},
};
var manager = new GeneratedManager(options);
return await manager.RunCommandAsync() ?? (int)ExitCode.CreateCommandFailure;