Skip to content

Commit 0e26e28

Browse files
committed
Align with usage in rust-libp2p
1 parent 46843df commit 0e26e28

File tree

2 files changed

+8
-1
lines changed

2 files changed

+8
-1
lines changed

Cargo.toml

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -31,3 +31,10 @@ bincode = "1"
3131
quickcheck = { version = "1.0.3", default-features = false }
3232
rand = "0.8.4"
3333
serde_json = "1.0"
34+
35+
# Passing arguments to the docsrs builder in order to properly document cfg's.
36+
# More information: https://docs.rs/about/builds#cross-compiling
37+
[package.metadata.docs.rs]
38+
all-features = true
39+
rustdoc-args = ["--cfg", "docsrs"]
40+
rustc-args = ["--cfg", "docsrs"]

src/lib.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
//! Implementation of [multiaddr](https://github.com/multiformats/multiaddr) in Rust.
2-
#![cfg_attr(doc, feature(doc_auto_cfg))]
2+
#![cfg_attr(docsrs, feature(doc_cfg, doc_auto_cfg))]
33

44
pub use multihash;
55

0 commit comments

Comments
 (0)