mirror of
https://github.com/balena-io/balena-cli.git
synced 2024-12-25 08:21:04 +00:00
eb74ca631a
Change-type: patch Signed-off-by: Scott Lowe <scott@balena.io>
44 lines
1.9 KiB
Diff
44 lines
1.9 KiB
Diff
diff --git a/node_modules/@oclif/plugin-help/lib/command.js b/node_modules/@oclif/plugin-help/lib/command.js
|
|
index 1caa65b..e205faf 100644
|
|
--- a/node_modules/@oclif/plugin-help/lib/command.js
|
|
+++ b/node_modules/@oclif/plugin-help/lib/command.js
|
|
@@ -87,7 +87,7 @@ class CommandHelp {
|
|
if (args.filter(a => a.description).length === 0)
|
|
return;
|
|
const body = list_1.renderList(args.map(a => {
|
|
- const name = a.name.toUpperCase();
|
|
+ const name = a.required ? `<${a.name}>` : `[${a.name}]`;
|
|
let description = a.description || '';
|
|
if (a.default)
|
|
description = `[default: ${a.default}] ${description}`;
|
|
@@ -130,9 +130,7 @@ class CommandHelp {
|
|
if (!flag.helpValue && flag.options) {
|
|
value = flag.options.join('|');
|
|
}
|
|
- if (!value.includes('|'))
|
|
- value = underline(value);
|
|
- left += `=${value}`;
|
|
+ left += ` <${value}>`;
|
|
}
|
|
let right = flag.description || '';
|
|
if (flag.type === 'option' && flag.default) {
|
|
diff --git a/node_modules/@oclif/plugin-help/lib/index.js b/node_modules/@oclif/plugin-help/lib/index.js
|
|
index 02646b6..525e19f 100644
|
|
--- a/node_modules/@oclif/plugin-help/lib/index.js
|
|
+++ b/node_modules/@oclif/plugin-help/lib/index.js
|
|
@@ -95,11 +95,12 @@ class Help extends HelpBase {
|
|
console.log(title + '\n');
|
|
console.log(this.formatCommand(command));
|
|
console.log('');
|
|
- if (subTopics.length > 0) {
|
|
+ const SUPPRESS_SUBTOPICS = true;
|
|
+ if (subTopics.length > 0 && !SUPPRESS_SUBTOPICS) {
|
|
console.log(this.formatTopics(subTopics));
|
|
console.log('');
|
|
}
|
|
- if (subCommands.length > 0) {
|
|
+ if (subCommands.length > 0 && !SUPPRESS_SUBTOPICS) {
|
|
console.log(this.formatCommands(subCommands));
|
|
console.log('');
|
|
}
|