commandlineparser / commandlineparser/commandline
Issue with boolean switch after verb
- Lenguaje dominante
- C#
- Estrellas
- 4.8k
- Forks
- 478
- Métricas de merge de PR
- Sin PR fusionados en 30 d
Descripción
**Issue**
When using a boolean switch after a verb, I cannot set it to false
**Example:**
app.exe install --feature=false
**Options class**
```
[Verb("install", HelpText = "Install something")]
class Options
{
[Option('f', "feature", Required = false, Default = true, HelpText = "Enable a feature")]
public bool EnableFeature { get; set; }
}
```
**Expected:**
Feature = False
**Actual result:**
Feature = True
**Demo code:**
[https://dotnetfiddle.net/lSBqxp](https://dotnetfiddle.net/lSBqxp)
**Edit1**
Add Options class code
Guía de contribución
No hay ninguna guía de contribución indexada para este repositorio
Evaluación
Este issue todavía no se ha evaluado.