Skip to content

Commit

Permalink
feat: implement info when not given PATH_TO_FARM for wipe info an…
Browse files Browse the repository at this point in the history
…d `scrub` (#2000)

* feat: implement info when not given PATH_TO_FARM for `wipe` `info` and `scrub`
  • Loading branch information
Iamshankhadeep authored Sep 25, 2023
1 parent 8744104 commit d410201
Showing 1 changed file with 15 additions and 3 deletions.
18 changes: 15 additions & 3 deletions crates/subspace-farmer/src/bin/subspace-farmer/main.rs
Original file line number Diff line number Diff line change
Expand Up @@ -260,16 +260,28 @@ async fn main() -> anyhow::Result<()> {
SingleDiskFarm::wipe(disk_farm)?;
}

info!("Done");
if disk_farms.is_empty() {
info!("No farm was specified, so there is nothing to do");
} else {
info!("Done");
}
}
Command::Farm(farming_args) => {
commands::farm::<PosTable>(farming_args).await?;
}
Command::Info { disk_farms } => {
commands::info(disk_farms);
if disk_farms.is_empty() {
info!("No farm was specified, so there is nothing to do");
} else {
commands::info(disk_farms);
}
}
Command::Scrub { disk_farms } => {
commands::scrub(&disk_farms);
if disk_farms.is_empty() {
info!("No farm was specified, so there is nothing to do");
} else {
commands::scrub(&disk_farms);
}
}
}
Ok(())
Expand Down

0 comments on commit d410201

Please sign in to comment.