xtask: Clean up doc output

* Don't render docs for examples
* Don't include a workaround for a problematic nightly feature we no longer use
This commit is contained in:
Jonas Platte 2022-09-16 11:45:45 +02:00 committed by Jonas Platte
parent cea8a9718a
commit c54b96dc69
2 changed files with 4 additions and 12 deletions

View File

@ -1,7 +1,7 @@
[workspace]
members = ["crates/*", "examples/*", "xtask"]
# xtask should only be compiled when invoked explicitly
default-members = ["crates/*", "examples/*"]
# Only compile / check / document the public crates by default
default-members = ["crates/*"]
resolver = "2"

View File

@ -20,16 +20,8 @@ impl DocTask {
rustdocflags += " -Dwarnings";
}
// Keep in sync with .github/workflows/docs.yml
let mut cmd = cmd!(
"
rustup run nightly cargo doc --all-features --no-deps --workspace
--exclude ruma-macros --exclude ruma-identifiers-validation --exclude xtask
"
)
// Work around https://github.com/rust-lang/cargo/issues/10744
.env("CARGO_TARGET_APPLIES_TO_HOST", "true")
.env("RUSTDOCFLAGS", rustdocflags);
let mut cmd = cmd!("rustup run nightly cargo doc --all-features --no-deps")
.env("RUSTDOCFLAGS", rustdocflags);
if self.open {
cmd = cmd.arg("--open");