[ 
https://issues.apache.org/jira/browse/HADOOP-9158?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13585916#comment-13585916
 ] 

Daryn Sharp commented on HADOOP-9158:
-------------------------------------

Just glancing at http://commons.apache.org/cli/usage.html:
* It appears to be able to format the help similar to the current output.  They 
show an ant example that includes the options.
* Do we need headers or footers to closely match the current output?  If we do, 
it shouldn't be hard to capture the text and add the indent with the equivalent 
of s/^/<spaces>/g.
* The source looks like it handles explicit newlines within the text to format.

Do you have an example of it mangling the desired output?

Stopping at the first non-arg (ie. {{PosixParser}} + {{stopAtNonOption}}) is ok 
because that's the current semantics of the shell.



                
> Tidy up fs -help
> ----------------
>
>                 Key: HADOOP-9158
>                 URL: https://issues.apache.org/jira/browse/HADOOP-9158
>             Project: Hadoop Common
>          Issue Type: Improvement
>            Reporter: Jonathan Allen
>            Assignee: Jonathan Allen
>            Priority: Minor
>         Attachments: HADOOP-9158.patch
>
>
> There are a number of issues with the current fs -help implementation that 
> could do with tidying up.
> 1) Running 'hadoop fs -help' displays the full detailed help for all 
> commands.  This produces a large amount of text and makes it hard to find 
> what you're looking for.  Better functionality would be:
> - hadoop fs -usage : shows the basic usage information for all commands
> - hadoop fs -help : shows usage and brief summary (couple of lines) for all 
> commands
> - hadoop fs -help <command> : shows full description of the specified command
> 2) Help text is hardcoded into each command class. This should be replaced by 
> resource files to allow internationalisation.
> 3) Line breaks are hardcoded into the help text. The help text should be 
> auto-formatted at display time.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira

Reply via email to