3
3
4
4
using System . CommandLine . Subsystems . Annotations ;
5
5
using System . CommandLine . Subsystems ;
6
- using static System . Runtime . InteropServices . JavaScript . JSType ;
7
6
8
7
namespace System . CommandLine ;
9
8
@@ -16,22 +15,24 @@ namespace System.CommandLine;
16
15
// var command = new CliCommand("greet")
17
16
// .With(help.Description, "Greet the user");
18
17
//
19
- public class HelpSubsystem ( IAnnotationProvider ? annotationProvider = null )
18
+ public class HelpSubsystem ( IAnnotationProvider ? annotationProvider = null )
20
19
: CliSubsystem ( HelpAnnotations . Prefix , SubsystemKind . Help , annotationProvider )
21
20
{
22
- public CliOption < bool > HelpOption { get ; } = new CliOption < bool > ( "--help" , [ "-h" ] )
23
- {
24
- // TODO: Why don't we accept bool like any other bool option?
25
- Arity = ArgumentArity . Zero
26
- } ;
21
+ public CliOption < bool > HelpOption { get ; } = new CliOption < bool > ( "--help" , [ "-h" ] )
22
+ {
23
+ // TODO: Why don't we accept bool like any other bool option?
24
+ Arity = ArgumentArity . Zero
25
+ } ;
27
26
28
- public void SetDescription ( CliSymbol symbol , string description )
27
+ public void SetDescription ( CliSymbol symbol , string description )
29
28
=> SetAnnotation ( symbol , HelpAnnotations . Description , description ) ;
30
- public string GetDescription ( CliSymbol symbol )
29
+
30
+ public string GetDescription ( CliSymbol symbol )
31
31
=> TryGetAnnotation < string > ( symbol , HelpAnnotations . Description , out var value )
32
32
? value
33
33
: "" ;
34
- public AnnotationAccessor < string > Description
34
+
35
+ public AnnotationAccessor < string > Description
35
36
=> new ( this , HelpAnnotations . Description ) ;
36
37
37
38
protected internal override CliConfiguration Initialize ( InitializationContext context )
0 commit comments