From 4b2837a4ccce923bc51e9b577460d257d16f9293 Mon Sep 17 00:00:00 2001 From: Ed Page Date: Tue, 6 Sep 2022 09:19:03 -0500 Subject: [PATCH] chore(ci): Ensure intradoc links are valid --- .github/workflows/main.yml | 4 +++- src/cargo/lib.rs | 1 + src/cargo/ops/fix.rs | 2 +- 3 files changed, 5 insertions(+), 2 deletions(-) diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index 760927932..21acb72ef 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -150,7 +150,9 @@ jobs: mkdir mdbook curl -Lf https://github.com/rust-lang/mdBook/releases/download/v0.4.5/mdbook-v0.4.5-x86_64-unknown-linux-gnu.tar.gz | tar -xz --directory=./mdbook echo `pwd`/mdbook >> $GITHUB_PATH - - run: cargo doc --no-deps + - run: cargo doc --document-private-items --no-deps + env: + RUSTDOCFLAGS: -D warnings - run: cd src/doc && mdbook build --dest-dir ../../target/doc - run: | cd src/doc diff --git a/src/cargo/lib.rs b/src/cargo/lib.rs index e93eae04c..f6aadcce9 100644 --- a/src/cargo/lib.rs +++ b/src/cargo/lib.rs @@ -5,6 +5,7 @@ // Due to some of the default clippy lints being somewhat subjective and not // necessarily an improvement, we prefer to not use them at this time. #![allow(clippy::all)] +#![allow(rustdoc::private_intra_doc_links)] //! # Cargo as a library //! diff --git a/src/cargo/ops/fix.rs b/src/cargo/ops/fix.rs index 5fb35b890..d143beb77 100644 --- a/src/cargo/ops/fix.rs +++ b/src/cargo/ops/fix.rs @@ -348,7 +348,7 @@ pub fn fix_get_proxy_lock_addr() -> Option { /// If there are warnings or errors, this does not return, /// and the process exits with the corresponding `rustc` exit code. /// -/// See [`fix_proxy_lock_addr`] +/// See [`fix_get_proxy_lock_addr`] pub fn fix_exec_rustc(config: &Config, lock_addr: &str) -> CargoResult<()> { let args = FixArgs::get()?; trace!("cargo-fix as rustc got file {:?}", args.file); -- 2.39.2