Meta Parser
Take comments from the head of a file and turn it into beautiful CLI ready text. This is primarily used for documentation of CLI tools.
Example:
#!/usr/bin/env node// # Basic Example//// Demonstrate the unbridled power of the Meta Parser//// ## Usage// ```// node ./examples/basic [command]// ```//// ## Commands// super - try it to find out// crazy - try it to find out// insane - try it to find out// help - output the help docs//// > Exits with 1 if given an unknown command// var metaParser = var command = processargv2 var helpDocs = if command === 'super' console else if command === 'crazy' console else if command === 'insane' console else if command === 'help' console else console process process
Result