commandlineparser / commandlineparser/commandline
How to parse a command line with an an invalid parameter
- Lingua principale
- C#
- Stelle
- 4.8k
- Fork
- 478
- Metriche di merge delle PR
- Nessuna PR unita negli ultimi 30g
Descrizione
I want to parse command line but with the possibility of providing an incorrect parameter.
I tried for example:
```
Parser.Default.ParseArguments(Environment.GetCommandLineArgs())
.WithNotParsed(errs => {
// code for errors
})
.WithParsed(opt => {
// code for valid options
});
```
but in situation when any command line parametr is incorrect commandline parser calls only code for errors handling ( "code for errors" in my example).
So how to handle valid parameters and skip incorrect?
Guida per i contributori
Nessuna guida per i contributori indicizzata per questo repository
Valutazione
Questa issue non è ancora stata valutata.