lexicalscope/jewelcli — Issue #11: Create a usage message explicitly
Author: tomwhoiscontrary
Created: 2012-02-24 14:24:38+00:00
State: open

It would be useful to be able to create the usage message without having a failed option parse.

My use case for this is that i have a number of unparsed arguments which must meet some moderately complex requirements (the first must be a URL, the second must be a method supported by the object referred to by that URL, etc), and if the user enters bad arguments, i would like to emit a usage message.

At the moment, i can say CliFactory.parseArguments(options.getClass(), "--help"), and handle the resulting exception as i would the exception from a failed option parse, but this is mildly icky.