slog-rs / slog

Structured, contextual, extensible, composable logging for Rust
https://slog.rs/
Apache License 2.0
1.58k stars 95 forks source link

ci: Check for rustdoc warnings #340

Open Techcable opened 2 months ago

Techcable commented 2 months ago

Right now, there are two rustdoc warnings that CI hasn't caught.

``` Compiling slog v2.8.0-beta.2 (/Users/nicholas/git/slog.org/slog) Documenting slog v2.8.0-beta.2 (/Users/nicholas/git/slog.org/slog) warning: this URL is not a hyperlink --> src/lib.rs:1332:30 | 1332 | /// default to `()` once https://github.com/rust-lang/rust/issues/29661 is | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ | = note: bare URLs are not automatically turned into clickable links = note: `#[warn(rustdoc::bare_urls)]` on by default help: use an automatic link instead | 1332 | /// default to `()` once is | + + warning: this URL is not a hyperlink --> src/lib.rs:1796:16 | 1796 | /// Reference: https://github.com/rust-lang/rust/issues/34511 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ | = note: bare URLs are not automatically turned into clickable links help: use an automatic link instead | 1796 | /// Reference: | + + warning: `slog` (lib doc) generated 2 warnings (run `cargo fix --lib -p slog` to apply 2 suggestions) Finished `dev` profile [unoptimized + debuginfo] target(s) in 1.84s Opening /Users/nicholas/git/slog.org/slog/target/doc/slog/index.html ```

It would be good to catch these automatically.