Skip to content
Snippets Groups Projects
Commit 9adbdf90 authored by Hugo Trentesaux's avatar Hugo Trentesaux Committed by Pascal Engélibert
Browse files

ref(node): remove cmd.shared_params.dev special case (!130)

* remove cmd.shared_params.dev special case

since --dev is a shortcut for --chain=dev
and that case is managed in load_spec
there is no need to manage it separately
parent ba2d4ee1
No related branches found
No related tags found
1 merge request!130remove cmd.shared_params.dev special case
Pipeline #18684 failed
......@@ -187,30 +187,7 @@ pub fn run() -> sc_cli::Result<()> {
match &cli.subcommand {
Some(Subcommand::BuildSpec(cmd)) => {
let runner = cli.create_runner(cmd)?;
runner.sync_run(|config| {
if cmd.shared_params.dev {
match config.chain_spec.runtime_type() {
#[cfg(feature = "g1")]
RuntimeType::G1 => cmd.run(
Box::new(chain_spec::g1::development_chain_spec()?),
config.network,
),
#[cfg(feature = "gtest")]
RuntimeType::GTest => cmd.run(
Box::new(chain_spec::gtest::development_chain_spec()?),
config.network,
),
#[cfg(feature = "gdev")]
RuntimeType::GDev => cmd.run(
Box::new(chain_spec::gdev::development_chain_spec()?),
config.network,
),
_ => panic!("unknown runtime"),
}
} else {
cmd.run(config.chain_spec, config.network)
}
})
runner.sync_run(|config| cmd.run(config.chain_spec, config.network))
}
Some(Subcommand::CheckBlock(cmd)) => {
let runner = cli.create_runner(cmd)?;
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment