-
Notifications
You must be signed in to change notification settings - Fork 116
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Generate man page and/or markdown #176
Comments
Hi, |
Hi, |
There is the help2man utility ;) |
Would pandoc really be necessary? ansi-wl-pprint is already a dependency, wouldn't this be enough to create nice man pages? |
@jneira pointed out: https://github.com/haskell/cabal/blob/00a2351789a460700a2567eb5ecc42cca0af913f/cabal-install/src/Distribution/Client/Manpage.hs Also note that |
Ta. |
FWIW, this feature is now available in opt-env-conf, see the announcing blog post for an example. |
Ta. That code has a more restrictive license than optparse, so it can't used directly. Good to know that it's relatively straight forwards though. I think that man pages in general could be a separate package to optparse proper, but I'm open to inclusion here as well. |
Really though, your man page is full documentation, not just options. So it's a bit of a kludge just automatically generating it. |
PRs welcome. |
Hi,
given the highly structured and detailed data a well-polished option parser, one would really like to be able to use it to also create other bits of reference documentation that one would expect, in particular a manpage and maybe also markdown snippets to put into the README.
Such a feature would likely pull in pandoc, and hence be better put into a package of its own. This way, the dependency could be just of a special “man-page generating” executable and not bloat the real thing.
I’m not sure if the current API is well suited for this task.
Thanks,
Joachim
The text was updated successfully, but these errors were encountered: