mirror of
https://github.com/pezkuwichain/pezkuwi-subxt.git
synced 2026-04-26 08:47:57 +00:00
use clap3 instead of structopt (#10632)
* use clap3 instead of structopt Signed-off-by: koushiro <koushiro.cqx@gmail.com> * format Signed-off-by: koushiro <koushiro.cqx@gmail.com> * update ss58-registry and revert some nits Signed-off-by: koushiro <koushiro.cqx@gmail.com> * Fix clippy and doc Signed-off-by: koushiro <koushiro.cqx@gmail.com> * update clap to 3.0.7 Signed-off-by: koushiro <koushiro.cqx@gmail.com> * Apply review suggestions Signed-off-by: koushiro <koushiro.cqx@gmail.com> * remove useless option long name Signed-off-by: koushiro <koushiro.cqx@gmail.com> * cargo fmt Signed-off-by: koushiro <koushiro.cqx@gmail.com>
This commit is contained in:
@@ -17,7 +17,7 @@ targets = ["x86_64-unknown-linux-gnu"]
|
||||
name = "node-template"
|
||||
|
||||
[dependencies]
|
||||
structopt = "0.3.25"
|
||||
clap = { version = "3.0", features = ["derive"] }
|
||||
|
||||
sc-cli = { version = "0.10.0-dev", path = "../../../client/cli", features = ["wasmtime"] }
|
||||
sp-core = { version = "4.1.0-dev", path = "../../../primitives/core" }
|
||||
@@ -59,6 +59,4 @@ substrate-build-script-utils = { version = "3.0.0", path = "../../../utils/build
|
||||
|
||||
[features]
|
||||
default = []
|
||||
runtime-benchmarks = [
|
||||
"node-template-runtime/runtime-benchmarks",
|
||||
]
|
||||
runtime-benchmarks = ["node-template-runtime/runtime-benchmarks"]
|
||||
|
||||
@@ -1,19 +1,20 @@
|
||||
use sc_cli::RunCmd;
|
||||
use structopt::StructOpt;
|
||||
|
||||
#[derive(Debug, StructOpt)]
|
||||
#[derive(Debug, clap::Parser)]
|
||||
pub struct Cli {
|
||||
#[structopt(subcommand)]
|
||||
#[clap(subcommand)]
|
||||
pub subcommand: Option<Subcommand>,
|
||||
|
||||
#[structopt(flatten)]
|
||||
#[clap(flatten)]
|
||||
pub run: RunCmd,
|
||||
}
|
||||
|
||||
#[derive(Debug, StructOpt)]
|
||||
#[derive(Debug, clap::Subcommand)]
|
||||
pub enum Subcommand {
|
||||
/// Key management cli utilities
|
||||
#[clap(subcommand)]
|
||||
Key(sc_cli::KeySubcommand),
|
||||
|
||||
/// Build a chain specification.
|
||||
BuildSpec(sc_cli::BuildSpecCmd),
|
||||
|
||||
@@ -36,6 +37,6 @@ pub enum Subcommand {
|
||||
Revert(sc_cli::RevertCmd),
|
||||
|
||||
/// The custom benchmark subcommand benchmarking runtime pallets.
|
||||
#[structopt(name = "benchmark", about = "Benchmark runtime pallets.")]
|
||||
#[clap(name = "benchmark", about = "Benchmark runtime pallets.")]
|
||||
Benchmark(frame_benchmarking_cli::BenchmarkCmd),
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user