commandlineparser / commandlineparser/commandline

Showing help with no arguments when you have a default verb

Abierto
#748 0 comentarios 0 reacciones 0 asignados Ver en GitHub
Lenguaje dominante
C#
Estrellas
4.8k
Forks
478
Métricas de merge de PR
Sin PR fusionados en 30 d

Descripción

I want to show the verbs help when you provide no arguments:

`tool` --> Shows verbs help.
`tool arg1 arg2` --> Executes default verb with those args.

By default, it either executes the default verb without arguments or, if this verb has required values, it shows the error and help for that verb.

My current workaround is this one, but I wonder if there is a neater way:

```csharp
if (args.Length == 0)
{
args = new[] { "--help" };
}
```

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.

Recibe los nuevos issues en tu correo

Un resumen breve de issues de GitHub para principiantes.