You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Describe the bug
When no long or short name is provided for an option, the help display this option in lowercase
To Reproduce
Run this console program adding in the command line "--help "
class Options
{
[Option(HelpText = "Specify the input file.")]
public string InputFile { get; set; }
}
class Program
{
static void Main(string[] args)
{
var result = Parser.Default.ParseArguments<Options>(args);
result.WithParsed(options =>
{
Console.WriteLine($"InputFile: {options.InputFile}");
})
.WithNotParsed(errors =>
{
});
}
}
Expected behavior
"InputFile" instead of "inputfile"
Screenshots
Additional context
I saw that it's in Specification.cs class method FromProperty that there is a call to ToLowerInvariant() that make the display lower
The text was updated successfully, but these errors were encountered:
Thanks for your answer.
I agree that specifying a longname solves the problem.
This requires specifying a longname for all options :-(
But I find it really unfortunate to have this default behavior...
Describe the bug
When no long or short name is provided for an option, the help display this option in lowercase
To Reproduce
Run this console program adding in the command line "--help "
Expected behavior
"InputFile" instead of "inputfile"
Screenshots
Additional context
I saw that it's in Specification.cs class method FromProperty that there is a call to ToLowerInvariant() that make the display lower
The text was updated successfully, but these errors were encountered: