@clerc/plugin-help 0.25.0 → 0.25.1
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 +7 -2
- package/dist/index.mjs +7 -2
- package/package.json +4 -4
package/dist/index.js
CHANGED
|
@@ -165,9 +165,12 @@ const generateSubcommandHelp = (render, ctx, command) => {
|
|
|
165
165
|
throw new NoSuchCommandError(formatCommandName(command));
|
|
166
166
|
}
|
|
167
167
|
const sections = [];
|
|
168
|
-
generateCliDetail(sections, cli,
|
|
168
|
+
generateCliDetail(sections, cli, {
|
|
169
|
+
...subcommand,
|
|
170
|
+
name: formatCommandName(command)
|
|
171
|
+
});
|
|
169
172
|
const parameters = ((_a = subcommand.parameters) == null ? void 0 : _a.join(" ")) || void 0;
|
|
170
|
-
const commandName =
|
|
173
|
+
const commandName = ` ${formatCommandName(command)}`;
|
|
171
174
|
const parametersString = parameters ? ` ${parameters}` : "";
|
|
172
175
|
const flagsString = subcommand.flags ? " [flags]" : "";
|
|
173
176
|
sections.push({
|
|
@@ -259,6 +262,8 @@ const helpPlugin = ({
|
|
|
259
262
|
} else {
|
|
260
263
|
printHelp(generateSubcommandHelp(render, ctx, ctx.raw._));
|
|
261
264
|
}
|
|
265
|
+
} else {
|
|
266
|
+
printHelp(generateSubcommandHelp(render, ctx, ctx.raw._));
|
|
262
267
|
}
|
|
263
268
|
} else {
|
|
264
269
|
printHelp(generateHelp(render, ctx, notes, examples));
|
package/dist/index.mjs
CHANGED
|
@@ -165,9 +165,12 @@ const generateSubcommandHelp = (render, ctx, command) => {
|
|
|
165
165
|
throw new NoSuchCommandError(formatCommandName(command));
|
|
166
166
|
}
|
|
167
167
|
const sections = [];
|
|
168
|
-
generateCliDetail(sections, cli,
|
|
168
|
+
generateCliDetail(sections, cli, {
|
|
169
|
+
...subcommand,
|
|
170
|
+
name: formatCommandName(command)
|
|
171
|
+
});
|
|
169
172
|
const parameters = ((_a = subcommand.parameters) == null ? void 0 : _a.join(" ")) || void 0;
|
|
170
|
-
const commandName =
|
|
173
|
+
const commandName = ` ${formatCommandName(command)}`;
|
|
171
174
|
const parametersString = parameters ? ` ${parameters}` : "";
|
|
172
175
|
const flagsString = subcommand.flags ? " [flags]" : "";
|
|
173
176
|
sections.push({
|
|
@@ -259,6 +262,8 @@ const helpPlugin = ({
|
|
|
259
262
|
} else {
|
|
260
263
|
printHelp(generateSubcommandHelp(render, ctx, ctx.raw._));
|
|
261
264
|
}
|
|
265
|
+
} else {
|
|
266
|
+
printHelp(generateSubcommandHelp(render, ctx, ctx.raw._));
|
|
262
267
|
}
|
|
263
268
|
} else {
|
|
264
269
|
printHelp(generateHelp(render, ctx, notes, examples));
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@clerc/plugin-help",
|
|
3
|
-
"version": "0.25.
|
|
3
|
+
"version": "0.25.1",
|
|
4
4
|
"author": "Ray <nn_201312@163.com> (https://github.com/so1ve)",
|
|
5
5
|
"description": "Clerc plugin help",
|
|
6
6
|
"keywords": [
|
|
@@ -54,11 +54,11 @@
|
|
|
54
54
|
"boxen": "^7.0.1",
|
|
55
55
|
"get-func-name": "^2.0.0",
|
|
56
56
|
"picocolors": "^1.0.0",
|
|
57
|
-
"@clerc/toolkit": "0.25.
|
|
58
|
-
"@clerc/utils": "0.25.
|
|
57
|
+
"@clerc/toolkit": "0.25.1",
|
|
58
|
+
"@clerc/utils": "0.25.1"
|
|
59
59
|
},
|
|
60
60
|
"devDependencies": {
|
|
61
|
-
"@clerc/core": "0.25.
|
|
61
|
+
"@clerc/core": "0.25.1"
|
|
62
62
|
},
|
|
63
63
|
"scripts": {
|
|
64
64
|
"build": "puild",
|