HomePhorge

(#6749) Fix optional vs mandatory argument handling.
5a0b547f3289Unpublished

Unpublished Commit ยท Learn More

Repository Importing: This repository is still importing.

Description

(#6749) Fix optional vs mandatory argument handling.

optparse will treat '--foo --bar' as "foo with the argument --bar" when foo
takes a mandatory argument. We need to emulate that behaviour in our
pre-parse of the command line.

Incidentally, fix up a bug in boolean options, and improve our testing.

Reviewed-By: Nick Lewis <nick@puppetlabs.com>

Details

Provenance
Daniel Pittman <daniel@puppetlabs.com>Authored on
vanmeeuwenPushed on Jun 2 2015, 2:22 PM
Parents
rPU8b37d7038c89: (#6749) Polish the CLI option pre-parse implementation
Branches
Unknown
Tags
Unknown

Event Timeline

Daniel Pittman <daniel@puppetlabs.com> committed rPU5a0b547f3289: (#6749) Fix optional vs mandatory argument handling. (authored by Daniel Pittman <daniel@puppetlabs.com>).Apr 4 2011, 10:32 PM