[jira] Created: (CLI-189) "Unexpected --help while processing"

classic Classic list List threaded Threaded
5 messages Options
Reply | Threaded
Open this post in threaded view
|

[jira] Created: (CLI-189) "Unexpected --help while processing"

JIRA jira@apache.org
"Unexpected --help while processing"
------------------------------------

                 Key: CLI-189
                 URL: https://issues.apache.org/jira/browse/CLI-189
             Project: Commons CLI
          Issue Type: Bug
          Components: CLI-2.x, Help formatter
    Affects Versions: 2.0
            Reporter: Guillaume Perrot


The help trigger feature seems not working.
When I pass --help to the command line, I have "Unexpected --help while processing", then usage is printed.
Code snippet:
{code:java}
 Parser parser = new Parser();
 parser.setGroup(group);
 parser.setHelpFormatter(new HelpFormatter());
 parser.setHelpTrigger("--help");
 parser.parseAndHelp(args);
{code}

--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.

Reply | Threaded
Open this post in threaded view
|

[jira] Updated: (CLI-189) "Unexpected --help while processing"

JIRA jira@apache.org

     [ https://issues.apache.org/jira/browse/CLI-189?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Guillaume Perrot updated CLI-189:
---------------------------------

    Environment: snapshot jar

> "Unexpected --help while processing"
> ------------------------------------
>
>                 Key: CLI-189
>                 URL: https://issues.apache.org/jira/browse/CLI-189
>             Project: Commons CLI
>          Issue Type: Bug
>          Components: CLI-2.x, Help formatter
>    Affects Versions: 2.0
>         Environment: snapshot jar
>            Reporter: Guillaume Perrot
>
> The help trigger feature seems not working.
> When I pass --help to the command line, I have "Unexpected --help while processing", then usage is printed.
> Code snippet:
> {code:java}
>  Parser parser = new Parser();
>  parser.setGroup(group);
>  parser.setHelpFormatter(new HelpFormatter());
>  parser.setHelpTrigger("--help");
>  parser.parseAndHelp(args);
> {code}

--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.

Reply | Threaded
Open this post in threaded view
|

[jira] Commented: (CLI-189) "Unexpected --help while processing"

JIRA jira@apache.org
In reply to this post by JIRA jira@apache.org

    [ https://issues.apache.org/jira/browse/CLI-189?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12769857#action_12769857 ]

Piotr Repetowski commented on CLI-189:
--------------------------------------

This is not a bug. First you should add help option to the group:
\\
\\
{code}
DefaultOptionBuilder obuilder = new DefaultOptionBuilder();
Option help = obuilder.withLongName("help").create();

group.withOption(help);

// Your code
{code}
\\
Kind regards.

> "Unexpected --help while processing"
> ------------------------------------
>
>                 Key: CLI-189
>                 URL: https://issues.apache.org/jira/browse/CLI-189
>             Project: Commons CLI
>          Issue Type: Bug
>          Components: CLI-2.x, Help formatter
>    Affects Versions: 2.0
>         Environment: snapshot jar
>            Reporter: Guillaume Perrot
>
> The help trigger feature seems not working.
> When I pass --help to the command line, I have "Unexpected --help while processing", then usage is printed.
> Code snippet:
> {code:java}
>  Parser parser = new Parser();
>  parser.setGroup(group);
>  parser.setHelpFormatter(new HelpFormatter());
>  parser.setHelpTrigger("--help");
>  parser.parseAndHelp(args);
> {code}

--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.

Reply | Threaded
Open this post in threaded view
|

[jira] Updated: (CLI-189) "Unexpected --help while processing"

JIRA jira@apache.org
In reply to this post by JIRA jira@apache.org

     [ https://issues.apache.org/jira/browse/CLI-189?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Emmanuel Bourg updated CLI-189:
-------------------------------

    Fix Version/s: 2.0

> "Unexpected --help while processing"
> ------------------------------------
>
>                 Key: CLI-189
>                 URL: https://issues.apache.org/jira/browse/CLI-189
>             Project: Commons CLI
>          Issue Type: Bug
>          Components: CLI-2.x, Help formatter
>    Affects Versions: 2.0
>         Environment: snapshot jar
>            Reporter: Guillaume Perrot
>             Fix For: 2.0
>
>
> The help trigger feature seems not working.
> When I pass --help to the command line, I have "Unexpected --help while processing", then usage is printed.
> Code snippet:
> {code:java}
>  Parser parser = new Parser();
>  parser.setGroup(group);
>  parser.setHelpFormatter(new HelpFormatter());
>  parser.setHelpTrigger("--help");
>  parser.parseAndHelp(args);
> {code}

--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.

Reply | Threaded
Open this post in threaded view
|

[jira] Resolved: (CLI-189) "Unexpected --help while processing"

JIRA jira@apache.org
In reply to this post by JIRA jira@apache.org

     [ https://issues.apache.org/jira/browse/CLI-189?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Emmanuel Bourg resolved CLI-189.
--------------------------------

    Resolution: Not A Problem

Closing since this is not an issue as explained by Piotr.

> "Unexpected --help while processing"
> ------------------------------------
>
>                 Key: CLI-189
>                 URL: https://issues.apache.org/jira/browse/CLI-189
>             Project: Commons CLI
>          Issue Type: Bug
>          Components: CLI-2.x, Help formatter
>    Affects Versions: 2.0
>         Environment: snapshot jar
>            Reporter: Guillaume Perrot
>             Fix For: 2.0
>
>
> The help trigger feature seems not working.
> When I pass --help to the command line, I have "Unexpected --help while processing", then usage is printed.
> Code snippet:
> {code:java}
>  Parser parser = new Parser();
>  parser.setGroup(group);
>  parser.setHelpFormatter(new HelpFormatter());
>  parser.setHelpTrigger("--help");
>  parser.parseAndHelp(args);
> {code}

--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.