The HelpFormatter always renders a space between the option name and value even if the option has a value separator that is not a space. For example, this option:
is rendered like this:
But I would expect it to be rendered like this:
For the automatically generated usage message, a similar problem exists. I changed it to try to use the value separator when rendering the option with the short name only if there's no long name. If there's no short name, it always tries to use the value separator with the long name rendering.
For example, consider this option containing a short name and a specified value separator:
The automatically generated usage message with my changes would look like this:
If the same option included a long name too:
with my changes the value separator is assumed to be meant for use with the long name. The short option rendering in the usage message will not try to use the value separator and will render the usage message like this:
Attached is a patch for these fixes with test cases. The patch is against http://svn.apache.org/repos/asf/commons/proper/cli/branches/cli-1.x.