dotnet / dotnet/command-line-api

Auto-removing quatation marks

Open
#1,345 1 comment 0 reactions 0 assignees View on GitHub
Area-Parser and Binder bug
Dominant language
C#
Stars
3.7k
Forks
428
PR merge metrics
No merged PRs in 30d

Description

Parser automatically removes quatation marks from begin or end of a arguments value (i. e. -name="miliver => -name=miliver).

```
string input = "run -name=\"miliver";
var rootCommand = new RootCommand
{
new Option
(
name: "-name",
)
};
string userName;
rootCommand.Handler = CommandHandler.Create((name) =>
{
userName = name;
});
await rootCommand.InvokeAsync(args);

//userName = miliver
```
I'm not sure if this is a bug or feature? Thank you for answer.

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.