@clerc/plugin-help 0.12.4 → 0.12.5

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.js CHANGED
@@ -88,20 +88,20 @@ const showHelp = (ctx, notes, examples) => {
88
88
  if (ctx.isSingleCommand) {
89
89
  sections.push({
90
90
  title: "Usage:",
91
- body: [`$ ${cli._name} [options]`]
91
+ body: [`$ ${cli._name} [flags]`]
92
92
  });
93
93
  } else {
94
94
  sections.push({
95
95
  title: "Usage:",
96
- body: [`$ ${cli._name} [command] [options]`]
96
+ body: [`$ ${cli._name} [command] [flags]`]
97
97
  });
98
98
  }
99
99
  if (!ctx.isSingleCommand) {
100
100
  sections.push({
101
101
  title: "Commands:",
102
- body: Object.values(cli._commands).map((command) => {
103
- return table([pc.cyan(command.name), DELIMITER, command.description]).toString();
104
- })
102
+ body: table(...Object.values(cli._commands).map((command) => {
103
+ return [pc.cyan(command.name), DELIMITER, command.description];
104
+ })).toString().split("\n")
105
105
  });
106
106
  }
107
107
  if (notes) {
@@ -127,7 +127,7 @@ const showSubcommandHelp = (ctx, command) => {
127
127
  const parameters = ((_a = subcommand.parameters) == null ? void 0 : _a.join(", ")) || "";
128
128
  sections.push({
129
129
  title: "Usage:",
130
- body: [`$ ${cli._name} ${subcommand.name}${parameters ? ` ${parameters}` : ""} [options]`]
130
+ body: [`$ ${cli._name} ${subcommand.name}${parameters ? ` ${parameters}` : ""} [flags]`]
131
131
  });
132
132
  if (subcommand.flags) {
133
133
  sections.push({
package/dist/index.mjs CHANGED
@@ -88,20 +88,20 @@ const showHelp = (ctx, notes, examples) => {
88
88
  if (ctx.isSingleCommand) {
89
89
  sections.push({
90
90
  title: "Usage:",
91
- body: [`$ ${cli._name} [options]`]
91
+ body: [`$ ${cli._name} [flags]`]
92
92
  });
93
93
  } else {
94
94
  sections.push({
95
95
  title: "Usage:",
96
- body: [`$ ${cli._name} [command] [options]`]
96
+ body: [`$ ${cli._name} [command] [flags]`]
97
97
  });
98
98
  }
99
99
  if (!ctx.isSingleCommand) {
100
100
  sections.push({
101
101
  title: "Commands:",
102
- body: Object.values(cli._commands).map((command) => {
103
- return table([pc.cyan(command.name), DELIMITER, command.description]).toString();
104
- })
102
+ body: table(...Object.values(cli._commands).map((command) => {
103
+ return [pc.cyan(command.name), DELIMITER, command.description];
104
+ })).toString().split("\n")
105
105
  });
106
106
  }
107
107
  if (notes) {
@@ -127,7 +127,7 @@ const showSubcommandHelp = (ctx, command) => {
127
127
  const parameters = ((_a = subcommand.parameters) == null ? void 0 : _a.join(", ")) || "";
128
128
  sections.push({
129
129
  title: "Usage:",
130
- body: [`$ ${cli._name} ${subcommand.name}${parameters ? ` ${parameters}` : ""} [options]`]
130
+ body: [`$ ${cli._name} ${subcommand.name}${parameters ? ` ${parameters}` : ""} [flags]`]
131
131
  });
132
132
  if (subcommand.flags) {
133
133
  sections.push({
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@clerc/plugin-help",
3
- "version": "0.12.4",
3
+ "version": "0.12.5",
4
4
  "author": "Ray <nn_201312@163.com> (https://github.com/so1ve)",
5
5
  "description": "Clerc plugin help",
6
6
  "keywords": [
@@ -52,11 +52,11 @@
52
52
  },
53
53
  "dependencies": {
54
54
  "picocolors": "^1.0.0",
55
- "@clerc/toolkit": "0.12.4",
56
- "@clerc/utils": "0.12.4"
55
+ "@clerc/toolkit": "0.12.5",
56
+ "@clerc/utils": "0.12.5"
57
57
  },
58
58
  "devDependencies": {
59
- "@clerc/core": "0.12.4"
59
+ "@clerc/core": "0.12.5"
60
60
  },
61
61
  "scripts": {
62
62
  "build": "puild",