commandlineparser / commandlineparser/commandline

verbs with same or options

Aberta
#935 0 comentários 0 reações 0 responsáveis Ver no GitHub
Linguagem predominante
C#
Estrelas
4.8k
Forks
478
Métricas de merge de PRs
Nenhum PR com merge em 30d

Descrição

Hello, I would like to ask you, whether there can be considered having some verbs with similar or even same options? That is, when the option classes have some relations like inheritance or they are based on same type in F#. Is there possibility to have somehow Parsed with additional info related to verb itself - like verb string or verb attribute?

An example in F#
```
open CommandLine

type CommonOptions = {
[]
ConnectionString: string
[]
DbCollection: string
[]
Directory: string
[]
BatchSize: int
[]
Skip: int
}
[]
type SerializeOptions = CommonOptions

[]
type DeserializeOptions = CommonOptions

```
Then the classic handling as described in the main page
` let result = Parser.Default.ParseArguments(argv) ...
`
won't work (matches with NotParsed).

Guia de contribuição

Nenhum guia de contribuição indexado para este repositório

Direção de pesquisa

Start with the F# example and the ParseArguments(argv) call shown in the issue. Trace how inherited CommonOptions and Verb attributes are handled, and determine whether shared option types and verb-specific information are supported. Done requires a clearly decided behavior for this case, with the issue's requested usage either supported or explicitly documented as unsupported.

Escrita pelo modelo de indexação a partir do texto da issue.

Avaliação

Stack de tecnologia
csharp, fsharp
Domínio
cli
Tipo de issue
Funcionalidade
Dificuldade
5/5
Tempo estimado
Mais de uma semana
Status de atividade
Estagnada
Clareza
Precisa de esclarecimento
Facilidade para iniciantes
22/100

Receba novas issues na sua caixa de entrada

Um resumo curto de issues do GitHub para quem está começando.