summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorBryan Newbold <bnewbold@archive.org>2021-02-10 11:13:05 -0800
committerBryan Newbold <bnewbold@archive.org>2021-02-10 11:13:05 -0800
commite992c92fc1210ba899a114c3007beecc73be8129 (patch)
treef6a05b943b0661a5e532f89933386fd36a4ee6d2
parent4f4c1e78186ad9bcd77f3536ef30dd5a130ec2d7 (diff)
downloadfatcat-cli-e992c92fc1210ba899a114c3007beecc73be8129.tar.gz
fatcat-cli-e992c92fc1210ba899a114c3007beecc73be8129.zip
editgroup -> editgroups
-rw-r--r--fatcat-cli/src/main.rs30
1 files changed, 15 insertions, 15 deletions
diff --git a/fatcat-cli/src/main.rs b/fatcat-cli/src/main.rs
index b3a5db3..055ac41 100644
--- a/fatcat-cli/src/main.rs
+++ b/fatcat-cli/src/main.rs
@@ -55,7 +55,7 @@ struct Opt {
}
#[derive(StructOpt)]
-enum EditgroupCommand {
+enum EditgroupsCommand {
/// Create a new editgroup
Create {
#[structopt(long, short)]
@@ -246,9 +246,9 @@ enum Command {
#[structopt(long = "--index-json")]
index_json: bool,
},
- Editgroup {
+ Editgroups {
#[structopt(subcommand)]
- cmd: EditgroupCommand,
+ cmd: EditgroupsCommand,
},
Changelog {
#[structopt(long, short = "-n", default_value = "20")]
@@ -596,9 +596,9 @@ fn run(opt: Opt) -> Result<()> {
let history_entries = specifier.get_history(&mut api_client, Some(limit))?;
print_entity_histories(history_entries, json)?;
}
- Command::Editgroup {
+ Command::Editgroups {
cmd:
- EditgroupCommand::List {
+ EditgroupsCommand::List {
editor_id,
limit,
json,
@@ -628,8 +628,8 @@ fn run(opt: Opt) -> Result<()> {
}
}
}
- Command::Editgroup {
- cmd: EditgroupCommand::Reviewable { limit, json },
+ Command::Editgroups {
+ cmd: EditgroupsCommand::Reviewable { limit, json },
} => {
let result = api_client
.rt
@@ -650,26 +650,26 @@ fn run(opt: Opt) -> Result<()> {
}
}
}
- Command::Editgroup {
- cmd: EditgroupCommand::Create { description },
+ Command::Editgroups {
+ cmd: EditgroupsCommand::Create { description },
} => {
let eg = api_client.create_editgroup(Some(description))?;
writeln!(&mut std::io::stdout(), "{}", to_colored_json_auto(&serde_json::to_value(&eg)?)?)?
}
- Command::Editgroup {
- cmd: EditgroupCommand::Accept { editgroup_id },
+ Command::Editgroups {
+ cmd: EditgroupsCommand::Accept { editgroup_id },
} => {
let msg = api_client.accept_editgroup(editgroup_id.clone())?;
writeln!(&mut std::io::stdout(), "{}", to_colored_json_auto(&serde_json::to_value(&msg)?)?)?
}
- Command::Editgroup {
- cmd: EditgroupCommand::Submit { editgroup_id },
+ Command::Editgroups {
+ cmd: EditgroupsCommand::Submit { editgroup_id },
} => {
let msg = api_client.update_editgroup_submit(editgroup_id, true)?;
writeln!(&mut std::io::stdout(), "{}", to_colored_json_auto(&serde_json::to_value(&msg)?)?)?
}
- Command::Editgroup {
- cmd: EditgroupCommand::Unsubmit { editgroup_id },
+ Command::Editgroups {
+ cmd: EditgroupsCommand::Unsubmit { editgroup_id },
} => {
let msg = api_client.update_editgroup_submit(editgroup_id, false)?;
writeln!(&mut std::io::stdout(), "{}", to_colored_json_auto(&serde_json::to_value(&msg)?)?)?