diff --git a/crates/radicle-cli/src/commands/help.rs b/crates/radicle-cli/src/commands/help.rs index 4f806c2f..6b3cc0db 100644 --- a/crates/radicle-cli/src/commands/help.rs +++ b/crates/radicle-cli/src/commands/help.rs @@ -94,7 +94,10 @@ const COMMANDS: &[CommandItem] = &[ name: "node", about: crate::commands::node::ABOUT, }, - CommandItem::Lexopt(crate::commands::patch::HELP), + CommandItem::Clap { + name: "patch", + about: crate::commands::patch::ABOUT, + }, CommandItem::Clap { name: "path", about: crate::commands::path::ABOUT, diff --git a/crates/radicle-cli/src/commands/patch.rs b/crates/radicle-cli/src/commands/patch.rs index e367efc6..20a3f77f 100644 --- a/crates/radicle-cli/src/commands/patch.rs +++ b/crates/radicle-cli/src/commands/patch.rs @@ -1,4 +1,5 @@ mod archive; +mod args; mod assign; mod cache; mod checkout; @@ -17,14 +18,11 @@ mod show; mod update; use std::collections::BTreeSet; -use std::ffi::OsString; -use std::str::FromStr as _; use anyhow::anyhow; use radicle::cob::patch::PatchId; -use radicle::cob::{patch, Label, Reaction}; -use radicle::git::fmt::RefString; +use radicle::cob::{patch, Label}; use radicle::patch::cache::Patches as _; use radicle::storage::git::transport; use radicle::{prelude::*, Node}; @@ -32,811 +30,15 @@ use radicle::{prelude::*, Node}; use crate::git::Rev; use crate::node; use crate::terminal as term; -use crate::terminal::args::{string, Args, Error, Help}; use crate::terminal::patch::Message; -pub const HELP: Help = Help { - name: "patch", - description: "Manage patches", - version: env!("RADICLE_VERSION"), - usage: r#" -Usage +pub use args::Args; +pub(crate) use args::ABOUT; - rad patch [