-
Notifications
You must be signed in to change notification settings - Fork 13.2k
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
Autogenerate man pages #98977
Comments
For CargoCargo seems to use Clap unlike Rustc and Rustdoc, which does have a utility for auto-generating man pages. For Rustc and RustdocRustc and Rustdoc use getopt, which does not include a utility for generating man pages. There is a common utility for this known as help2man, which gives a relatively good enough output. Although, some customization might be needed to improve it. [Which, fortunately, help2man allows.] Current command to generate man pages for rustc/rustdoc [Not final1] ->
Current flags passed to help2man
1 - help2man's output is not perfect.
2 - The autogenerated man pages lack detailed-information such as
One may compare on their own by comparing the outputs using the following commands [On Unix-y systems and using Rustup]
3 - While It doesn't include in-depth information about for eg. Codegen options, those are split into separate help messages ( |
Looks like Cargo has manually-written Markdown that is converted with its own mdman. |
Right now the man pages need to be manually updated, which in practice means they're almost never updated. We should find a way to autogenerate these if we want them to be accurate.
Originally posted by @jyn514 in #98975 (comment)
The text was updated successfully, but these errors were encountered: