CliArgumentAttribute.Name Property
Definition
- Namespace
- DotMake.CommandLine
- Assembly
- DotMake.CommandLine.dll
Gets or sets the name of the argument that will be used mainly for displaying in usage help of the command line application.
If not set (or is empty/whitespace), the name of the property that this attribute is applied to, will be used to generate argument name automatically:
These suffixes will be stripped from the property name: RootCliCommandArgument, RootCommandArgument, SubCliCommandArgument, SubCommandArgument, CliCommandArgument, CommandArgument, CliArgument, Argument.
Then the name will be converted to kebab-case, for example:
- If property name is
OutputorOutputArgumentorOutputCliArgument-> argument name will beoutput - If property name is
ProjectPathorProjectPathArgumentorProjectPathCliArgument-> argument name will beproject-path
Default convention can be changed via parent command's NameCasingConvention property.
public string Name { get; set; }