From ffa12344787163812d0f2c4f160d2955fc898b3f Mon Sep 17 00:00:00 2001 From: cyphersnake Date: Fri, 14 Apr 2023 15:20:12 +0400 Subject: [PATCH] ci: add cargo-doc --- .github/workflows/rust.yml | 16 ++++++++++++++-- src/chain_ids.rs | 16 ++++++++-------- src/debridge_accounts.rs | 4 ++-- 3 files changed, 24 insertions(+), 12 deletions(-) diff --git a/.github/workflows/rust.yml b/.github/workflows/rust.yml index 86e64e7..ef2c281 100644 --- a/.github/workflows/rust.yml +++ b/.github/workflows/rust.yml @@ -43,7 +43,13 @@ jobs: uses: actions-rs/cargo@v1 with: command: test - args: --all --verbose + args: --all --doc --verbose + + - name: Doc + uses: actions-rs/cargo@v1 + with: + command: doc + args: --no-deps build_example: @@ -84,7 +90,13 @@ jobs: uses: actions-rs/cargo@v1 with: command: test - args: --manifest-path=example-program/Cargo.toml --verbose + args: --manifest-path=example-program/Cargo.toml --doc --verbose + + - name: Doc + uses: actions-rs/cargo@v1 + with: + command: doc + args: --no-deps linting_ts_example: name: Linting TS example diff --git a/src/chain_ids.rs b/src/chain_ids.rs index 7b274b1..f633ab5 100644 --- a/src/chain_ids.rs +++ b/src/chain_ids.rs @@ -1,5 +1,5 @@ /// This constant represents the solana chain id -/// Check https://chainlist.org/ for other chain ids +/// Check for other chain ids /// /// Within our network, we use the chain id as the /// identifier for each network. @@ -9,7 +9,7 @@ pub const SOLANA_CHAIN_ID: [u8; 32] = [ ]; /// This constant represents the eth chain id -/// Check https://chainlist.org/ for other chain ids +/// Check for other chain ids /// /// Within our network, we use the chain id as the /// identifier for each network. @@ -18,7 +18,7 @@ pub const ETHEREUM_CHAIN_ID: [u8; 32] = [ ]; /// This constant represents the bnb chain id -/// Check https://chainlist.org/ for other chain ids +/// Check for other chain ids /// /// Within our network, we use the chain id as the /// identifier for each network. @@ -27,7 +27,7 @@ pub const BNB_CHAIN_CHAIN_ID: [u8; 32] = [ ]; /// This constant represents the heco chain id -/// Check https://chainlist.org/ for other chain ids +/// Check for other chain ids /// /// Within our network, we use the chain id as the /// identifier for each network. @@ -37,7 +37,7 @@ pub const HECO_CHAIN_ID: [u8; 32] = [ ]; /// This constant represents the polygon chain id -/// Check https://chainlist.org/ for other chain ids +/// Check for other chain ids /// /// Within our network, we use the chain id as the /// identifier for each network. @@ -47,7 +47,7 @@ pub const POLYGON_CHAIN_ID: [u8; 32] = [ ]; /// This constant represents the arbitrum chain id -/// Check https://chainlist.org/ for other chain ids +/// Check for other chain ids /// /// Within our network, we use the chain id as the /// identifier for each network. @@ -57,7 +57,7 @@ pub const ARBITRUM_CHAIN_ID: [u8; 32] = [ ]; /// This constant represents the avalanche chain id -/// Check https://chainlist.org/ for other chain ids +/// Check for other chain ids /// /// Within our network, we use the chain id as the /// identifier for each network. @@ -67,7 +67,7 @@ pub const AVALANCHE_CHAIN_ID: [u8; 32] = [ ]; /// This constant represents the fantom chain id -/// Check https://chainlist.org/ for other chain ids +/// Check for other chain ids /// /// Within our network, we use the chain id as the /// identifier for each network. diff --git a/src/debridge_accounts.rs b/src/debridge_accounts.rs index e80ab21..d80fc4b 100644 --- a/src/debridge_accounts.rs +++ b/src/debridge_accounts.rs @@ -68,8 +68,8 @@ impl Discriminator for SubmissionAccount { /// Internal information about chain support and commissions within it /// # Variants -/// * [`ChainSupportInfoVariant::NotSupported`] - this chain not supported -/// * [`ChainSupportInfoVariant::Supported`] - this chain supported and we have `fixed_fee` & `transfer_fee` values for it +/// * [`ChainSupportInfo::NotSupported`] - this chain not supported +/// * [`ChainSupportInfo::Supported`] - this chain supported and we have `fixed_fee` & `transfer_fee` values for it #[derive(BorshSerialize, BorshDeserialize, Clone, Debug)] pub enum ChainSupportInfo { NotSupported,