From 494a10a1ff67de35bd08580e88acd4722a72bf8b Mon Sep 17 00:00:00 2001 From: Robin Lambertz Date: Mon, 21 Sep 2020 15:01:40 +0000 Subject: [PATCH] Show MakeConnection on docs.rs documentation. --- tower-make/Cargo.toml | 4 ++++ tower-make/src/lib.rs | 3 +++ 2 files changed, 7 insertions(+) diff --git a/tower-make/Cargo.toml b/tower-make/Cargo.toml index 360509048..f1f23bfaa 100644 --- a/tower-make/Cargo.toml +++ b/tower-make/Cargo.toml @@ -19,3 +19,7 @@ connect = ["tokio"] [dependencies] tower-service = "0.3" tokio = { version = "0.2", optional = true } + +[package.metadata.docs.rs] +all-features = true +rustdoc-args = ["--cfg", "docsrs"] \ No newline at end of file diff --git a/tower-make/src/lib.rs b/tower-make/src/lib.rs index 5977f9685..95576f278 100644 --- a/tower-make/src/lib.rs +++ b/tower-make/src/lib.rs @@ -5,14 +5,17 @@ rust_2018_idioms, unreachable_pub )] +#![cfg_attr(docsrs, feature(doc_cfg))] //! Trait aliases for Services that produce specific types of Responses. #[cfg(feature = "connect")] +#[cfg_attr(docsrs, doc(cfg(feature = "connect")))] mod make_connection; mod make_service; #[cfg(feature = "connect")] +#[cfg_attr(docsrs, doc(cfg(feature = "connect")))] pub use crate::make_connection::MakeConnection; pub use crate::make_service::MakeService;