@mercury-fw/cli-engine 0.31.1 → 0.32.0
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/CHANGELOG.md +6 -0
- package/cli-tool.ts +4 -5
- package/cli-version-check.ts +3 -5
- package/dist/cli-version-check.d.ts +3 -5
- package/package.json +2 -2
package/CHANGELOG.md
CHANGED
package/cli-tool.ts
CHANGED
|
@@ -16,10 +16,9 @@
|
|
|
16
16
|
* which can appear before the subcommand) consumed generically by
|
|
17
17
|
* `stripGlobalFlags` — no more hand-written per-CLI stripping function.
|
|
18
18
|
*
|
|
19
|
-
* Used by: `
|
|
20
|
-
*
|
|
21
|
-
*
|
|
22
|
-
* alongside the real `runCli`.
|
|
19
|
+
* Used by: each CLI plugin's `build()`, which validates its own allowlist
|
|
20
|
+
* (via `cli-config-loader.ts`) into the `Record<string, CliConfig>` and
|
|
21
|
+
* passes it into `createCliTool` alongside the real `runCli`.
|
|
23
22
|
*/
|
|
24
23
|
import { tool, type JSONValue } from "ai";
|
|
25
24
|
import { z } from "zod";
|
|
@@ -166,7 +165,7 @@ export function createCliTool(
|
|
|
166
165
|
stashDisplay?: (artifact: string) => string;
|
|
167
166
|
},
|
|
168
167
|
): { runCommand: ExecutableTool } {
|
|
169
|
-
// Anchor the example on a binary
|
|
168
|
+
// Anchor the example on a binary this tool actually runs rather than
|
|
170
169
|
// a hardcoded one: a fixed `jira …` example misleads the model on an instance
|
|
171
170
|
// without Jira. The concrete, CLI-specific example (real subcommand + flags)
|
|
172
171
|
// belongs to that CLI's own skill, not to this plugin-agnostic tool.
|
package/cli-version-check.ts
CHANGED
|
@@ -1,11 +1,9 @@
|
|
|
1
1
|
/**
|
|
2
2
|
* Checks an installed CLI binary's version against a maintainer-declared
|
|
3
3
|
* `minVersion` (from an externally-configured CLI config file, see
|
|
4
|
-
* `src/tools/cli-config-loader.ts`).
|
|
5
|
-
*
|
|
6
|
-
*
|
|
7
|
-
* a download asset, never validates an already-installed binary) and the
|
|
8
|
-
* rest of `src/`.
|
|
4
|
+
* `src/tools/cli-config-loader.ts`). Nothing else validates an
|
|
5
|
+
* already-installed binary: provisioning downloads a pinned version and
|
|
6
|
+
* never checks it again.
|
|
9
7
|
*
|
|
10
8
|
* Assumes `--version` is the right flag to invoke — the CLIs are
|
|
11
9
|
* Rust/clap-based, and `--version` is clap's near-universal default, but
|
|
@@ -1,11 +1,9 @@
|
|
|
1
1
|
/**
|
|
2
2
|
* Checks an installed CLI binary's version against a maintainer-declared
|
|
3
3
|
* `minVersion` (from an externally-configured CLI config file, see
|
|
4
|
-
* `src/tools/cli-config-loader.ts`).
|
|
5
|
-
*
|
|
6
|
-
*
|
|
7
|
-
* a download asset, never validates an already-installed binary) and the
|
|
8
|
-
* rest of `src/`.
|
|
4
|
+
* `src/tools/cli-config-loader.ts`). Nothing else validates an
|
|
5
|
+
* already-installed binary: provisioning downloads a pinned version and
|
|
6
|
+
* never checks it again.
|
|
9
7
|
*
|
|
10
8
|
* Assumes `--version` is the right flag to invoke — the CLIs are
|
|
11
9
|
* Rust/clap-based, and `--version` is clap's near-universal default, but
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@mercury-fw/cli-engine",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.32.0",
|
|
4
4
|
"license": "MIT",
|
|
5
5
|
"repository": {
|
|
6
6
|
"type": "git",
|
|
@@ -23,7 +23,7 @@
|
|
|
23
23
|
}
|
|
24
24
|
},
|
|
25
25
|
"dependencies": {
|
|
26
|
-
"@mercury-fw/plugin-types": "0.
|
|
26
|
+
"@mercury-fw/plugin-types": "0.32.0",
|
|
27
27
|
"ai": "^7.0.126",
|
|
28
28
|
"shell-quote": "^1.11.0",
|
|
29
29
|
"zod": "^4.6.5"
|