Parsing help output #565
                  
                    
                      kitschpatrol
                    
                  
                
                  started this conversation in
                Ideas
              
            Replies: 1 comment
-
| 
         Hi! That is an interesting idea... I was using the help text converter in zsh when first playing with autocomplete, so there may be some other cool use cases.  | 
  
Beta Was this translation helpful? Give feedback.
                  
                    0 replies
                  
                
            
  
    Sign up for free
    to join this conversation on GitHub.
    Already have an account?
    Sign in to comment
  
        
    
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
It can be useful to parse the output of a command line tool's help (
--help/-h) to generate documentation.Of course this is a bit tricky since help output isn't consistently formatted, many tools have subcommands, etc., though one could probably cover a majority of tools by implementing parsers for the output of the most popular CLI frameworks (e.g. Yargs, Click, etc.)
I've partially implemented this via Chevrotain for another project (before discovering jc), with support for parsing Yargs and Meow help output.
This is ultimately used to automatically generate Markdown tables enumerating available commands and options of various tools in readme documentation.
Just a thought! Thanks for a brilliant tool.
Beta Was this translation helpful? Give feedback.
All reactions