Skip to content

Commit

Permalink
node: Document check-blocks subcommands
Browse files Browse the repository at this point in the history
  • Loading branch information
tilacog committed Sep 23, 2022
1 parent d1910b0 commit 18f0513
Showing 1 changed file with 9 additions and 2 deletions.
11 changes: 9 additions & 2 deletions node/src/bin/manager.rs
Original file line number Diff line number Diff line change
Expand Up @@ -386,7 +386,6 @@ pub enum ChainCommand {
CheckBlocks {
#[clap(subcommand)] // Note that we mark a field as a subcommand
method: CheckBlockMethod,

/// Chain name (must be an existing chain, see 'chain list')
#[clap(empty_values = false)]
chain_name: String,
Expand Down Expand Up @@ -497,20 +496,28 @@ pub enum IndexCommand {
#[derive(Clone, Debug, Subcommand)]
pub enum CheckBlockMethod {
/// The hash of the target block
ByHash { hash: String },
ByHash {
/// The block hash to verify
hash: String,
},

/// The number of the target block
ByNumber {
/// The block number to verify
number: i32,
/// Delete duplicated blocks (by number) if found
delete_duplicates: bool,
},

/// A block number range, inclusive on both ends.
ByRange {
/// The first block number to verify
#[clap(long, short)]
from: Option<i32>,
/// The last block number to verify
#[clap(long, short)]
to: Option<i32>,
/// Delete duplicated blocks (by number) if found
delete_duplicates: bool,
},
}
Expand Down

0 comments on commit 18f0513

Please sign in to comment.