mirror of
https://git.proxmox.com/git/proxmox
synced 2025-08-06 02:45:53 +00:00
make cli format a bit saner
this looks more like pve/pmg cli tools now without double the empty lines Signed-off-by: Dominik Csapak <d.csapak@proxmox.com> Signed-off-by: Wolfgang Bumiller <w.bumiller@proxmox.com>
This commit is contained in:
parent
d84f563d5b
commit
d1bfafe157
@ -144,10 +144,10 @@ pub fn generate_usage_str(
|
|||||||
|
|
||||||
let mut text = match format {
|
let mut text = match format {
|
||||||
DocumentationFormat::Short => {
|
DocumentationFormat::Short => {
|
||||||
return format!("{}{}{}{}\n\n", indent, prefix, args, option_indicator);
|
return format!("{}{}{}{}\n", indent, prefix, args, option_indicator);
|
||||||
}
|
}
|
||||||
DocumentationFormat::Long => {
|
DocumentationFormat::Long => {
|
||||||
format!("{}{}{}{}\n\n", indent, prefix, args, option_indicator)
|
format!("{}{}{}{}\n", indent, prefix, args, option_indicator)
|
||||||
}
|
}
|
||||||
DocumentationFormat::Full => format!(
|
DocumentationFormat::Full => format!(
|
||||||
"{}{}{}{}\n\n{}\n\n",
|
"{}{}{}{}\n\n{}\n\n",
|
||||||
@ -166,7 +166,6 @@ pub fn generate_usage_str(
|
|||||||
if !options.is_empty() {
|
if !options.is_empty() {
|
||||||
text.push_str("Optional parameters:\n\n");
|
text.push_str("Optional parameters:\n\n");
|
||||||
text.push_str(&options);
|
text.push_str(&options);
|
||||||
text.push('\n');
|
|
||||||
}
|
}
|
||||||
text
|
text
|
||||||
}
|
}
|
||||||
|
@ -150,7 +150,6 @@ pub fn get_property_description(
|
|||||||
let indent = " ";
|
let indent = " ";
|
||||||
text.push('\n');
|
text.push('\n');
|
||||||
text.push_str(&wrap_text(indent, indent, descr, 80));
|
text.push_str(&wrap_text(indent, indent, descr, 80));
|
||||||
text.push('\n');
|
|
||||||
|
|
||||||
text
|
text
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user