-
Notifications
You must be signed in to change notification settings - Fork 9
Parsing options
Matthias Beerens edited this page Nov 5, 2019
·
1 revision
It is possible to configure how the parser behaves using CommandLineParserOptions
.
using MatthiWare.CommandLine;
static void Main(string[] args)
{
var options = new CommandLineParserOptions
{
AppName = "CLI.Tutorial", // Will be used in case of help or error message
PrefixShortOption = "/", // Required prefix for the short version of the option
PrefixLongOption = "--", // Required prefix for the long version of the option
PostfixOption = "=" // Postfix options are optional
};
var parser = new CommandLineParser(options);
// Further configuration
}
> Example.exe /opt="My String" /flag --longOption=1