-
Notifications
You must be signed in to change notification settings - Fork 256
Improve documentation generation #554
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
Conversation
Making it draft for now. There is good stuff in this PR, but it might need to be split. Besides, it looks like there are pre-existing clippy issues. |
rustdoc_use_unstable
to use unstable rustdoc features
Simplified, PR updated. No new feature is needed anymore. Ready for review. The clippy failure is addressed in #555. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nice!
One comment, but LGTM otherwise.
Cargo.toml
Outdated
rustdoc-args = ["--cfg", "docsrs"] | ||
targets = ["aarch64-apple-ios", "aarch64-linux-android", "x86_64-apple-darwin", "x86_64-unknown-fuchsia", "x86_64-pc-windows-msvc", "x86_64-pc-solaris", "x86_64-unknown-freebsd", "x86_64-unknown-illumos", "x86_64-unknown-linux-gnu", "x86_64-unknown-linux-musl", "x86_64-unknown-netbsd", "x86_64-unknown-redox", "armv7-linux-androideabi", "i686-linux-android"] | ||
targets = [ | ||
"x86_64-unknown-linux-gnu", |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Let's keep this list sorted and set default-target
instead, see https://docs.rs/about/metadata.
Make `x86_64-unknown-linux-gnu` the default target, as it's more feature rich. Users may not realize that they can select their platform on docs.rs, so it's better to show them more extensive documentation. Don't pass `--cfg docsrs` to rustdoc for docs.rs builds, it's already passed by docs.rs. Generate documentation about supported platforms automatically from the `cfg` attributes.
|
Thanks @proski! |
Make `x86_64-unknown-linux-gnu` the default target, as it's more feature rich. Users may not realize that they can select their platform on docs.rs, so it's better to show them more extensive documentation. Don't pass `--cfg docsrs` to rustdoc for docs.rs builds, it's already passed by docs.rs. Generate documentation about supported platforms automatically from the `cfg` attributes.
Make
x86_64-unknown-linux-gnu
the default target, as it's more feature rich.Users may not realize that they can select their platform on docs.rs, so it's
better to show them more extensive documentation.
Don't pass
--cfg docsrs
to rustdoc for docs.rs builds, it's already passed bydocs.rs.
Generate documentation about supported platforms automatically from the
cfg
attributes.