commons-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Michal Srb (JIRA)" <j...@apache.org>
Subject [jira] [Created] (CLI-253) Unrecognized option: --null
Date Fri, 19 Jun 2015 13:15:00 GMT
Michal Srb created CLI-253:
------------------------------

             Summary: Unrecognized option: --null
                 Key: CLI-253
                 URL: https://issues.apache.org/jira/browse/CLI-253
             Project: Commons CLI
          Issue Type: Bug
          Components: CLI-1.x
    Affects Versions: 1.3.1, 1.3
            Reporter: Michal Srb


groovy project uses commons-cli in following way:
      
{code:java}
options.addOption(OptionBuilder.hasArg().withArgName("path").withDescription("Specify where
to find the class files - must be first argument").create("classpath"));
      options.addOption(OptionBuilder.withLongOpt("classpath").hasArg().withArgName("path").withDescription("Aliases
for '-classpath'").create("cp"));
{code}

https://github.com/groovy/groovy-core/blob/GROOVY_1_8_X/src/main/org/codehaus/groovy/tools/FileSystemCompiler.java#L297-L298

When called with long option "--classpath ...", it throws exception:
org.apache.commons.cli.UnrecognizedOptionException: Unrecognized option: --null

Same code works fine with commons-cli 1.2.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

Mime
View raw message