Overlapping concepts: RootCommand, CliConfiguration and the Parser
These three things work together to define what ParseOperation does. Consider nmaking Parser an instance that contains configuration information and a RootCommand.
This is similar to argparse.
The configuration properties could be directly on the parser.
The rootcommand could contain methods that allow customization of the RootCommand that delegates to the Command instance. The concept of a RootCommand has been confusing to some, especially needing to add a command when the options and arguments appeared to be on the application.
A similar outcome would occur if Parser inherited from CliCommand, but that feels a bit weird.
Unclear concepts: Pipeline (new in Powderhouse)
The pipeline is how you will access full feature behavior, like the behavior you have today in System.CommandLine. For most users, it will be the most common way of accessing System.CommandLine behavior. Pipeline does not convey that concept.
Consider renaming to Cli and having Cli be the standard full featured CLI. Have another class named EmptyCli if folks wanted to start from an empty pipeline.
What seems about right
Symbols, options, arguments, and commands
Overlapping concepts:
RootCommand
,CliConfiguration
and theParser
These three things work together to define what
ParseOperation
does. Consider nmakingParser
an instance that contains configuration information and a RootCommand.This is similar to
argparse
.The configuration properties could be directly on the parser.
The rootcommand could contain methods that allow customization of the
RootCommand
that delegates to theCommand
instance. The concept of a RootCommand has been confusing to some, especially needing to add a command when the options and arguments appeared to be on the application.A similar outcome would occur if
Parser
inherited fromCliCommand
, but that feels a bit weird.Unclear concepts:
Pipeline
(new in Powderhouse)The pipeline is how you will access full feature behavior, like the behavior you have today in System.CommandLine. For most users, it will be the most common way of accessing System.CommandLine behavior. Pipeline does not convey that concept.
Consider renaming to
Cli
and havingCli
be the standard full featured CLI. Have another class namedEmptyCli
if folks wanted to start from an empty pipeline.