commandline icon indicating copy to clipboard operation
commandline copied to clipboard

ParseArgumentsStrict overload gone?

Open Plasma opened this issue 7 years ago • 1 comments

Hey,

The documentation in the README says to use:

static int Main(string[] args) {
  var options = new Options();
  var isValid = CommandLine.Parser.Default.ParseArgumentsStrict(args, options);

However this ParseArgumentsStrict method is missing.

I've ended up having to do something like this?

var isValid = Parser.Default.ParseArguments<Options>(args);
if (isValid.Tag == ParserResultType.NotParsed)
    return 1;

Log.Info("Name: " + ((Parsed<Options>)isValid).Value.Name);

Is this how I'm supposed to now retrieve the Name property of Options class? Thanks

Plasma avatar Apr 26 '17 00:04 Plasma

Hi, can you post your Options class please?

If with README you're talking about the WIKI, this is correct because 2.0.x beta lacks ParseArgumentsStrict and WIKI is about 1.9.x stable.

Bye and thanks for posting!

gsscoder avatar May 12 '17 06:05 gsscoder