@optique/run 1.3.0-dev.2352 → 1.3.0-dev.2357
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/run.cjs +2 -0
- package/dist/run.d.cts +15 -0
- package/dist/run.d.ts +15 -0
- package/dist/run.js +2 -0
- package/package.json +4 -4
package/dist/run.cjs
CHANGED
|
@@ -77,6 +77,7 @@ function buildCoreOptions(options, programMetadata) {
|
|
|
77
77
|
const showDefault = options.showDefault;
|
|
78
78
|
const showChoices = options.showChoices;
|
|
79
79
|
const showUsage = options.showUsage;
|
|
80
|
+
const usageLine = options.usageLine;
|
|
80
81
|
const commandList = options.commandList;
|
|
81
82
|
const sectionOrder = options.sectionOrder;
|
|
82
83
|
const help = options.help;
|
|
@@ -155,6 +156,7 @@ function buildCoreOptions(options, programMetadata) {
|
|
|
155
156
|
showDefault,
|
|
156
157
|
showChoices,
|
|
157
158
|
showUsage,
|
|
159
|
+
usageLine,
|
|
158
160
|
commandList,
|
|
159
161
|
sectionOrder,
|
|
160
162
|
help: helpConfig,
|
package/dist/run.d.cts
CHANGED
|
@@ -5,6 +5,7 @@ import { InferMode, InferValue, Mode, ModeValue, Parser } from "@optique/core/pa
|
|
|
5
5
|
import { Program } from "@optique/core/program";
|
|
6
6
|
import { DocSection, ShowChoicesOptions, ShowDefaultOptions } from "@optique/core/doc";
|
|
7
7
|
import { Message } from "@optique/core/message";
|
|
8
|
+
import { Usage } from "@optique/core/usage";
|
|
8
9
|
|
|
9
10
|
//#region src/run.d.ts
|
|
10
11
|
|
|
@@ -95,6 +96,20 @@ interface RunOptions {
|
|
|
95
96
|
* @since 1.2.0
|
|
96
97
|
*/
|
|
97
98
|
readonly showUsage?: boolean;
|
|
99
|
+
/**
|
|
100
|
+
* Usage line override for top-level full help.
|
|
101
|
+
*
|
|
102
|
+
* This option customizes the usage shown by `--help`, the root help command,
|
|
103
|
+
* and `aboveError: "help"` at the root. It does not affect subcommand help,
|
|
104
|
+
* parsing, shell completion, or usage-only error preambles from
|
|
105
|
+
* `aboveError: "usage"`.
|
|
106
|
+
*
|
|
107
|
+
* The callback form receives the generated root usage after built-in help,
|
|
108
|
+
* version, and completion entries have been added.
|
|
109
|
+
*
|
|
110
|
+
* @since 1.3.0
|
|
111
|
+
*/
|
|
112
|
+
readonly usageLine?: Usage | ((defaultUsageLine: Usage) => Usage);
|
|
98
113
|
/**
|
|
99
114
|
* How to render command lists in top-level help pages.
|
|
100
115
|
*
|
package/dist/run.d.ts
CHANGED
|
@@ -5,6 +5,7 @@ import { SourceContext } from "@optique/core/context";
|
|
|
5
5
|
import { InferMode, InferValue, Mode, ModeValue, Parser } from "@optique/core/parser";
|
|
6
6
|
import { Program } from "@optique/core/program";
|
|
7
7
|
import { DocSection, ShowChoicesOptions, ShowDefaultOptions } from "@optique/core/doc";
|
|
8
|
+
import { Usage } from "@optique/core/usage";
|
|
8
9
|
|
|
9
10
|
//#region src/run.d.ts
|
|
10
11
|
|
|
@@ -95,6 +96,20 @@ interface RunOptions {
|
|
|
95
96
|
* @since 1.2.0
|
|
96
97
|
*/
|
|
97
98
|
readonly showUsage?: boolean;
|
|
99
|
+
/**
|
|
100
|
+
* Usage line override for top-level full help.
|
|
101
|
+
*
|
|
102
|
+
* This option customizes the usage shown by `--help`, the root help command,
|
|
103
|
+
* and `aboveError: "help"` at the root. It does not affect subcommand help,
|
|
104
|
+
* parsing, shell completion, or usage-only error preambles from
|
|
105
|
+
* `aboveError: "usage"`.
|
|
106
|
+
*
|
|
107
|
+
* The callback form receives the generated root usage after built-in help,
|
|
108
|
+
* version, and completion entries have been added.
|
|
109
|
+
*
|
|
110
|
+
* @since 1.3.0
|
|
111
|
+
*/
|
|
112
|
+
readonly usageLine?: Usage | ((defaultUsageLine: Usage) => Usage);
|
|
98
113
|
/**
|
|
99
114
|
* How to render command lists in top-level help pages.
|
|
100
115
|
*
|
package/dist/run.js
CHANGED
|
@@ -76,6 +76,7 @@ function buildCoreOptions(options, programMetadata) {
|
|
|
76
76
|
const showDefault = options.showDefault;
|
|
77
77
|
const showChoices = options.showChoices;
|
|
78
78
|
const showUsage = options.showUsage;
|
|
79
|
+
const usageLine = options.usageLine;
|
|
79
80
|
const commandList = options.commandList;
|
|
80
81
|
const sectionOrder = options.sectionOrder;
|
|
81
82
|
const help = options.help;
|
|
@@ -154,6 +155,7 @@ function buildCoreOptions(options, programMetadata) {
|
|
|
154
155
|
showDefault,
|
|
155
156
|
showChoices,
|
|
156
157
|
showUsage,
|
|
158
|
+
usageLine,
|
|
157
159
|
commandList,
|
|
158
160
|
sectionOrder,
|
|
159
161
|
help: helpConfig,
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@optique/run",
|
|
3
|
-
"version": "1.3.0-dev.
|
|
3
|
+
"version": "1.3.0-dev.2357",
|
|
4
4
|
"description": "Type-safe combinatorial command-line interface parser",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"CLI",
|
|
@@ -76,15 +76,15 @@
|
|
|
76
76
|
},
|
|
77
77
|
"sideEffects": false,
|
|
78
78
|
"dependencies": {
|
|
79
|
-
"@optique/core": "1.3.0-dev.
|
|
79
|
+
"@optique/core": "1.3.0-dev.2357+dcd8c5c2"
|
|
80
80
|
},
|
|
81
81
|
"devDependencies": {
|
|
82
82
|
"@types/node": "^24.0.0",
|
|
83
83
|
"fast-check": "^4.7.0",
|
|
84
84
|
"tsdown": "^0.13.0",
|
|
85
85
|
"typescript": "^5.8.3",
|
|
86
|
-
"@optique/config": "1.3.0-dev.
|
|
87
|
-
"@optique/env": "1.3.0-dev.
|
|
86
|
+
"@optique/config": "1.3.0-dev.2357+dcd8c5c2",
|
|
87
|
+
"@optique/env": "1.3.0-dev.2357+dcd8c5c2"
|
|
88
88
|
},
|
|
89
89
|
"scripts": {
|
|
90
90
|
"build": "tsdown",
|