From 6a168ad57ad13ea0896f7684120f4fa15bfef474 Mon Sep 17 00:00:00 2001 From: Lulu Date: Mon, 29 Jan 2024 13:17:44 +0000 Subject: [PATCH] Link mermaid docs to crate that uses them (#3087) While including files cross crate works locally. When pushed to crates.io each crate is seperate so the file path no longer exists. Instead change it to a symlink, which cargo will change to a read directory when published. --- substrate/primitives/runtime/docs | 1 + substrate/primitives/runtime/src/generic/unchecked_extrinsic.rs | 2 +- 2 files changed, 2 insertions(+), 1 deletion(-) create mode 120000 substrate/primitives/runtime/docs diff --git a/substrate/primitives/runtime/docs b/substrate/primitives/runtime/docs new file mode 120000 index 0000000000..48c4a0c02f --- /dev/null +++ b/substrate/primitives/runtime/docs @@ -0,0 +1 @@ +../../../docs \ No newline at end of file diff --git a/substrate/primitives/runtime/src/generic/unchecked_extrinsic.rs b/substrate/primitives/runtime/src/generic/unchecked_extrinsic.rs index f066de2323..5b54caf597 100644 --- a/substrate/primitives/runtime/src/generic/unchecked_extrinsic.rs +++ b/substrate/primitives/runtime/src/generic/unchecked_extrinsic.rs @@ -57,7 +57,7 @@ type UncheckedSignaturePayload = (Address, Signature, /// could in principle be any other interaction. Transactions are either signed or unsigned. A /// sensible transaction pool should ensure that only transactions that are worthwhile are /// considered for block-building. -#[cfg_attr(feature = "std", doc = simple_mermaid::mermaid!("../../../../../docs/mermaid/extrinsics.mmd"))] +#[cfg_attr(feature = "std", doc = simple_mermaid::mermaid!("../../docs/mermaid/extrinsics.mmd"))] /// This type is by no means enforced within Substrate, but given its genericness, it is highly /// likely that for most use-cases it will suffice. Thus, the encoding of this type will dictate /// exactly what bytes should be sent to a runtime to transact with it.