dotnet / dotnet/command-line-api

Add support for --no-option-options

Open
#2,736 6 comments 1 reaction 0 assignees View on GitHub
Dominant language
C#
Stars
3.7k
Forks
428
PR merge metrics
No merged PRs in 30d

Description

Many *nix programs have options that follow this pattern:

```
--option=yes|no
--(no-)option
```

I know that one could easily just supply a boolean option, as shown, but often times an additional option is accepted that prefixes the main option name with `no-` to indicate the option should not be used/present.

It would be great to support that.

Another way this _might_ be supported is via custom option processing, such as adding an alias for `--no-option` and detecting the use of the alias, and then allowing for the customization of help to properly document the API.

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.