@executioncontrolprotocol/cli 0.50.0 → 0.60.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/README.md +6 -156
- package/bin/dev.js +7 -3
- package/bin/ecp.js +6 -3
- package/bin/run.cmd +2 -3
- package/bin/run.js +1 -2
- package/bin/setup-env.js +42 -0
- package/dist/commands/app.d.ts +22 -0
- package/dist/commands/app.d.ts.map +1 -0
- package/dist/commands/app.js +75 -0
- package/dist/commands/app.js.map +1 -0
- package/dist/commands/commit.d.ts +24 -0
- package/dist/commands/commit.d.ts.map +1 -0
- package/dist/commands/commit.js +76 -0
- package/dist/commands/commit.js.map +1 -0
- package/dist/commands/config/secrets/list.d.ts +17 -0
- package/dist/commands/config/secrets/list.d.ts.map +1 -0
- package/dist/commands/config/secrets/list.js +41 -0
- package/dist/commands/config/secrets/list.js.map +1 -0
- package/dist/commands/config/secrets/set.d.ts +21 -0
- package/dist/commands/config/secrets/set.d.ts.map +1 -0
- package/dist/commands/config/secrets/set.js +86 -0
- package/dist/commands/config/secrets/set.js.map +1 -0
- package/dist/commands/config/secrets/unset.d.ts +20 -0
- package/dist/commands/config/secrets/unset.d.ts.map +1 -0
- package/dist/commands/config/secrets/unset.js +42 -0
- package/dist/commands/config/secrets/unset.js.map +1 -0
- package/dist/commands/execute.d.ts +27 -0
- package/dist/commands/execute.d.ts.map +1 -0
- package/dist/commands/execute.js +92 -0
- package/dist/commands/execute.js.map +1 -0
- package/dist/commands/host/logs.d.ts +19 -0
- package/dist/commands/host/logs.d.ts.map +1 -0
- package/dist/commands/host/logs.js +53 -0
- package/dist/commands/host/logs.js.map +1 -0
- package/dist/commands/host/reload.d.ts +15 -0
- package/dist/commands/host/reload.d.ts.map +1 -0
- package/dist/commands/host/reload.js +17 -0
- package/dist/commands/host/reload.js.map +1 -0
- package/dist/commands/host/restart.d.ts +18 -0
- package/dist/commands/host/restart.d.ts.map +1 -0
- package/dist/commands/host/restart.js +42 -0
- package/dist/commands/host/restart.js.map +1 -0
- package/dist/commands/host/start.d.ts +20 -0
- package/dist/commands/host/start.d.ts.map +1 -0
- package/dist/commands/host/start.js +100 -0
- package/dist/commands/host/start.js.map +1 -0
- package/dist/commands/host/status.d.ts +17 -0
- package/dist/commands/host/status.d.ts.map +1 -0
- package/dist/commands/host/status.js +86 -0
- package/dist/commands/host/status.js.map +1 -0
- package/dist/commands/host/stop.d.ts +18 -0
- package/dist/commands/host/stop.d.ts.map +1 -0
- package/dist/commands/host/stop.js +62 -0
- package/dist/commands/host/stop.js.map +1 -0
- package/dist/commands/mcp/start.d.ts +14 -0
- package/dist/commands/mcp/start.d.ts.map +1 -0
- package/dist/commands/mcp/start.js +42 -0
- package/dist/commands/mcp/start.js.map +1 -0
- package/dist/commands/plugins/index.d.ts +18 -0
- package/dist/commands/plugins/index.d.ts.map +1 -0
- package/dist/commands/plugins/index.js +55 -0
- package/dist/commands/plugins/index.js.map +1 -0
- package/dist/commands/plugins/inspect.d.ts +23 -0
- package/dist/commands/plugins/inspect.d.ts.map +1 -0
- package/dist/commands/plugins/inspect.js +113 -0
- package/dist/commands/plugins/inspect.js.map +1 -0
- package/dist/commands/plugins/install.d.ts +23 -0
- package/dist/commands/plugins/install.d.ts.map +1 -0
- package/dist/commands/plugins/install.js +135 -0
- package/dist/commands/plugins/install.js.map +1 -0
- package/dist/commands/plugins/link.d.ts +22 -0
- package/dist/commands/plugins/link.d.ts.map +1 -0
- package/dist/commands/plugins/link.js +90 -0
- package/dist/commands/plugins/link.js.map +1 -0
- package/dist/commands/plugins/reset.d.ts +20 -0
- package/dist/commands/plugins/reset.d.ts.map +1 -0
- package/dist/commands/plugins/reset.js +112 -0
- package/dist/commands/plugins/reset.js.map +1 -0
- package/dist/commands/plugins/uninstall.d.ts +27 -0
- package/dist/commands/plugins/uninstall.d.ts.map +1 -0
- package/dist/commands/plugins/uninstall.js +89 -0
- package/dist/commands/plugins/uninstall.js.map +1 -0
- package/dist/commands/plugins/update.d.ts +18 -0
- package/dist/commands/plugins/update.d.ts.map +1 -0
- package/dist/commands/plugins/update.js +75 -0
- package/dist/commands/plugins/update.js.map +1 -0
- package/dist/commands/retrieve.d.ts +26 -0
- package/dist/commands/retrieve.d.ts.map +1 -0
- package/dist/commands/retrieve.js +97 -0
- package/dist/commands/retrieve.js.map +1 -0
- package/dist/hooks/init.d.ts +9 -0
- package/dist/hooks/init.d.ts.map +1 -0
- package/dist/hooks/init.js +12 -0
- package/dist/hooks/init.js.map +1 -0
- package/dist/hooks/plugins-changed.d.ts +26 -0
- package/dist/hooks/plugins-changed.d.ts.map +1 -0
- package/dist/hooks/plugins-changed.js +106 -0
- package/dist/hooks/plugins-changed.js.map +1 -0
- package/dist/index.d.ts +9 -0
- package/dist/index.d.ts.map +1 -0
- package/dist/index.js +8 -0
- package/dist/index.js.map +1 -0
- package/dist/lib/control-client.d.ts +20 -0
- package/dist/lib/control-client.d.ts.map +1 -0
- package/dist/lib/control-client.js +49 -0
- package/dist/lib/control-client.js.map +1 -0
- package/dist/lib/exit.d.ts +12 -0
- package/dist/lib/exit.d.ts.map +1 -0
- package/dist/lib/exit.js +27 -0
- package/dist/lib/exit.js.map +1 -0
- package/dist/lib/help-quality.d.ts +17 -0
- package/dist/lib/help-quality.d.ts.map +1 -0
- package/dist/lib/help-quality.js +53 -0
- package/dist/lib/help-quality.js.map +1 -0
- package/dist/lib/home.d.ts +39 -0
- package/dist/lib/home.d.ts.map +1 -0
- package/dist/lib/home.js +98 -0
- package/dist/lib/home.js.map +1 -0
- package/dist/lib/host-discovery.d.ts +78 -0
- package/dist/lib/host-discovery.d.ts.map +1 -0
- package/dist/lib/host-discovery.js +315 -0
- package/dist/lib/host-discovery.js.map +1 -0
- package/dist/lib/host-unavailable.d.ts +16 -0
- package/dist/lib/host-unavailable.d.ts.map +1 -0
- package/dist/lib/host-unavailable.js +23 -0
- package/dist/lib/host-unavailable.js.map +1 -0
- package/dist/lib/input.d.ts +35 -0
- package/dist/lib/input.d.ts.map +1 -0
- package/dist/lib/input.js +80 -0
- package/dist/lib/input.js.map +1 -0
- package/dist/lib/output.d.ts +69 -0
- package/dist/lib/output.d.ts.map +1 -0
- package/dist/lib/output.js +295 -0
- package/dist/lib/output.js.map +1 -0
- package/dist/lib/plugin-mgmt.d.ts +194 -0
- package/dist/lib/plugin-mgmt.d.ts.map +1 -0
- package/dist/lib/plugin-mgmt.js +278 -0
- package/dist/lib/plugin-mgmt.js.map +1 -0
- package/dist/lib/secrets.d.ts +7 -0
- package/dist/lib/secrets.d.ts.map +1 -0
- package/dist/lib/secrets.js +31 -0
- package/dist/lib/secrets.js.map +1 -0
- package/dist/version.d.ts +6 -0
- package/dist/version.d.ts.map +1 -0
- package/dist/version.js +7 -0
- package/dist/version.js.map +1 -0
- package/oclif.manifest.json +1109 -0
- package/package.json +46 -40
- package/dist/commands.d.ts +0 -7
- package/dist/commands.d.ts.map +0 -1
- package/dist/commands.js +0 -9
- package/dist/commands.js.map +0 -1
- package/dist/hooks/command-not-found.d.ts +0 -8
- package/dist/hooks/command-not-found.d.ts.map +0 -1
- package/dist/hooks/command-not-found.js +0 -72
- package/dist/hooks/command-not-found.js.map +0 -1
- package/dist/hooks/init-host.d.ts +0 -8
- package/dist/hooks/init-host.d.ts.map +0 -1
- package/dist/hooks/init-host.js +0 -45
- package/dist/hooks/init-host.js.map +0 -1
- package/dist/hooks/jit-install.d.ts +0 -8
- package/dist/hooks/jit-install.d.ts.map +0 -1
- package/dist/hooks/jit-install.js +0 -32
- package/dist/hooks/jit-install.js.map +0 -1
- package/dist/hooks/trust.d.ts +0 -9
- package/dist/hooks/trust.d.ts.map +0 -1
- package/dist/hooks/trust.js +0 -32
- package/dist/hooks/trust.js.map +0 -1
- package/dist/lib/argv.d.ts +0 -11
- package/dist/lib/argv.d.ts.map +0 -1
- package/dist/lib/argv.js +0 -30
- package/dist/lib/argv.js.map +0 -1
- package/dist/lib/command-helpers.d.ts +0 -14
- package/dist/lib/command-helpers.d.ts.map +0 -1
- package/dist/lib/command-helpers.js +0 -37
- package/dist/lib/command-helpers.js.map +0 -1
- package/dist/lib/confirm.d.ts +0 -16
- package/dist/lib/confirm.d.ts.map +0 -1
- package/dist/lib/confirm.js +0 -49
- package/dist/lib/confirm.js.map +0 -1
- package/dist/lib/ensure-plugins.d.ts +0 -17
- package/dist/lib/ensure-plugins.d.ts.map +0 -1
- package/dist/lib/ensure-plugins.js +0 -38
- package/dist/lib/ensure-plugins.js.map +0 -1
- package/dist/lib/evaluate-trust.d.ts +0 -26
- package/dist/lib/evaluate-trust.d.ts.map +0 -1
- package/dist/lib/evaluate-trust.js +0 -87
- package/dist/lib/evaluate-trust.js.map +0 -1
- package/dist/lib/format-output.d.ts +0 -17
- package/dist/lib/format-output.d.ts.map +0 -1
- package/dist/lib/format-output.js +0 -63
- package/dist/lib/format-output.js.map +0 -1
- package/dist/lib/init/collect-env-packages.d.ts +0 -14
- package/dist/lib/init/collect-env-packages.d.ts.map +0 -1
- package/dist/lib/init/collect-env-packages.js +0 -36
- package/dist/lib/init/collect-env-packages.js.map +0 -1
- package/dist/lib/init/merge-package-json.d.ts +0 -29
- package/dist/lib/init/merge-package-json.d.ts.map +0 -1
- package/dist/lib/init/merge-package-json.js +0 -56
- package/dist/lib/init/merge-package-json.js.map +0 -1
- package/dist/lib/installed-plugins.d.ts +0 -25
- package/dist/lib/installed-plugins.d.ts.map +0 -1
- package/dist/lib/installed-plugins.js +0 -22
- package/dist/lib/installed-plugins.js.map +0 -1
- package/dist/lib/jit-plugins.d.ts +0 -13
- package/dist/lib/jit-plugins.d.ts.map +0 -1
- package/dist/lib/jit-plugins.js +0 -25
- package/dist/lib/jit-plugins.js.map +0 -1
- package/dist/lib/layer-environment.d.ts +0 -29
- package/dist/lib/layer-environment.d.ts.map +0 -1
- package/dist/lib/layer-environment.js +0 -96
- package/dist/lib/layer-environment.js.map +0 -1
- package/dist/lib/load-ecp.d.ts +0 -17
- package/dist/lib/load-ecp.d.ts.map +0 -1
- package/dist/lib/load-ecp.js +0 -39
- package/dist/lib/load-ecp.js.map +0 -1
- package/dist/lib/missing-plugins.d.ts +0 -24
- package/dist/lib/missing-plugins.d.ts.map +0 -1
- package/dist/lib/missing-plugins.js +0 -53
- package/dist/lib/missing-plugins.js.map +0 -1
- package/dist/lib/npm-registry.d.ts +0 -40
- package/dist/lib/npm-registry.d.ts.map +0 -1
- package/dist/lib/npm-registry.js +0 -68
- package/dist/lib/npm-registry.js.map +0 -1
- package/dist/lib/plugin-bindings.d.ts +0 -13
- package/dist/lib/plugin-bindings.d.ts.map +0 -1
- package/dist/lib/plugin-bindings.js +0 -49
- package/dist/lib/plugin-bindings.js.map +0 -1
- package/dist/lib/plugin-source.d.ts +0 -11
- package/dist/lib/plugin-source.d.ts.map +0 -1
- package/dist/lib/plugin-source.js +0 -32
- package/dist/lib/plugin-source.js.map +0 -1
- package/dist/lib/prepare-workflow.d.ts +0 -27
- package/dist/lib/prepare-workflow.d.ts.map +0 -1
- package/dist/lib/prepare-workflow.js +0 -76
- package/dist/lib/prepare-workflow.js.map +0 -1
- package/dist/lib/runs-io.d.ts +0 -30
- package/dist/lib/runs-io.d.ts.map +0 -1
- package/dist/lib/runs-io.js +0 -154
- package/dist/lib/runs-io.js.map +0 -1
- package/dist/lib/secrets/store.d.ts +0 -4
- package/dist/lib/secrets/store.d.ts.map +0 -1
- package/dist/lib/secrets/store.js +0 -6
- package/dist/lib/secrets/store.js.map +0 -1
- package/dist/lib/trust-store.d.ts +0 -12
- package/dist/lib/trust-store.d.ts.map +0 -1
- package/dist/lib/trust-store.js +0 -33
- package/dist/lib/trust-store.js.map +0 -1
- package/dist/operations/catalog.d.ts +0 -7
- package/dist/operations/catalog.d.ts.map +0 -1
- package/dist/operations/catalog.js +0 -108
- package/dist/operations/catalog.js.map +0 -1
- package/dist/operations/discover.d.ts +0 -3
- package/dist/operations/discover.d.ts.map +0 -1
- package/dist/operations/discover.js +0 -61
- package/dist/operations/discover.js.map +0 -1
- package/dist/operations/index.d.ts +0 -4
- package/dist/operations/index.d.ts.map +0 -1
- package/dist/operations/index.js +0 -38
- package/dist/operations/index.js.map +0 -1
- package/dist/operations/init.d.ts +0 -3
- package/dist/operations/init.d.ts.map +0 -1
- package/dist/operations/init.js +0 -46
- package/dist/operations/init.js.map +0 -1
- package/dist/operations/install.d.ts +0 -3
- package/dist/operations/install.d.ts.map +0 -1
- package/dist/operations/install.js +0 -34
- package/dist/operations/install.js.map +0 -1
- package/dist/operations/plugins.d.ts +0 -7
- package/dist/operations/plugins.d.ts.map +0 -1
- package/dist/operations/plugins.js +0 -64
- package/dist/operations/plugins.js.map +0 -1
- package/dist/operations/rollback.d.ts +0 -3
- package/dist/operations/rollback.d.ts.map +0 -1
- package/dist/operations/rollback.js +0 -25
- package/dist/operations/rollback.js.map +0 -1
- package/dist/operations/runs.d.ts +0 -11
- package/dist/operations/runs.d.ts.map +0 -1
- package/dist/operations/runs.js +0 -205
- package/dist/operations/runs.js.map +0 -1
- package/dist/operations/secrets.d.ts +0 -11
- package/dist/operations/secrets.d.ts.map +0 -1
- package/dist/operations/secrets.js +0 -134
- package/dist/operations/secrets.js.map +0 -1
- package/dist/operations/update.d.ts +0 -3
- package/dist/operations/update.d.ts.map +0 -1
- package/dist/operations/update.js +0 -64
- package/dist/operations/update.js.map +0 -1
- package/dist/operations/workflow.d.ts +0 -7
- package/dist/operations/workflow.d.ts.map +0 -1
- package/dist/operations/workflow.js +0 -144
- package/dist/operations/workflow.js.map +0 -1
package/package.json
CHANGED
|
@@ -1,70 +1,76 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@executioncontrolprotocol/cli",
|
|
3
|
-
"version": "0.
|
|
4
|
-
"description": "ECP command-line interface",
|
|
5
|
-
"license": "Apache-2.0",
|
|
3
|
+
"version": "0.60.0",
|
|
4
|
+
"description": "ECP command-line interface.",
|
|
6
5
|
"type": "module",
|
|
6
|
+
"engines": {
|
|
7
|
+
"node": ">=22.12"
|
|
8
|
+
},
|
|
7
9
|
"bin": {
|
|
8
10
|
"ecp": "./bin/ecp.js"
|
|
9
11
|
},
|
|
12
|
+
"exports": {
|
|
13
|
+
".": {
|
|
14
|
+
"types": "./dist/index.d.ts",
|
|
15
|
+
"import": "./dist/index.js"
|
|
16
|
+
},
|
|
17
|
+
"./bin/ecp.js": "./bin/ecp.js"
|
|
18
|
+
},
|
|
19
|
+
"types": "./dist/index.d.ts",
|
|
10
20
|
"files": [
|
|
11
|
-
"bin
|
|
12
|
-
"
|
|
13
|
-
"
|
|
14
|
-
"bin/dev.js",
|
|
15
|
-
"dist"
|
|
21
|
+
"bin",
|
|
22
|
+
"dist",
|
|
23
|
+
"oclif.manifest.json"
|
|
16
24
|
],
|
|
17
|
-
"peerDependencies": {
|
|
18
|
-
"zod": "^3.24.0",
|
|
19
|
-
"@executioncontrolprotocol/core": "^0.50.0"
|
|
20
|
-
},
|
|
21
25
|
"dependencies": {
|
|
22
26
|
"@oclif/core": "^5.1.8",
|
|
23
|
-
"@oclif/plugin-autocomplete": "^3.2.38",
|
|
24
27
|
"@oclif/plugin-help": "^6.2.33",
|
|
25
28
|
"@oclif/plugin-not-found": "^3.2.68",
|
|
26
|
-
"@oclif/plugin-plugins": "
|
|
27
|
-
"@
|
|
28
|
-
"
|
|
29
|
-
"@executioncontrolprotocol/
|
|
30
|
-
"@executioncontrolprotocol/
|
|
31
|
-
"@executioncontrolprotocol/
|
|
29
|
+
"@oclif/plugin-plugins": "5.5.2",
|
|
30
|
+
"@executioncontrolprotocol/engine": "0.60.0",
|
|
31
|
+
"@executioncontrolprotocol/host": "0.60.0",
|
|
32
|
+
"@executioncontrolprotocol/local": "0.60.0",
|
|
33
|
+
"@executioncontrolprotocol/mcp-relay": "0.60.0",
|
|
34
|
+
"@executioncontrolprotocol/protocol": "0.60.0"
|
|
32
35
|
},
|
|
33
36
|
"devDependencies": {
|
|
34
|
-
"
|
|
35
|
-
"
|
|
37
|
+
"@types/node": "^22.0.0",
|
|
38
|
+
"oclif": "^6.0.15",
|
|
39
|
+
"typescript": "^5.9.0"
|
|
36
40
|
},
|
|
37
41
|
"oclif": {
|
|
38
42
|
"bin": "ecp",
|
|
39
43
|
"dirname": "ecp",
|
|
40
44
|
"topicSeparator": " ",
|
|
41
|
-
"commands":
|
|
42
|
-
"strategy": "explicit",
|
|
43
|
-
"target": "./dist/commands.js",
|
|
44
|
-
"identifier": "COMMANDS"
|
|
45
|
-
},
|
|
45
|
+
"commands": "./dist/commands",
|
|
46
46
|
"scope": "executioncontrolprotocol",
|
|
47
|
-
"pluginPrefix": "plugin",
|
|
48
47
|
"plugins": [
|
|
49
48
|
"@oclif/plugin-help",
|
|
50
|
-
"@oclif/plugin-
|
|
51
|
-
"@oclif/plugin-not-found",
|
|
52
|
-
"@oclif/plugin-autocomplete",
|
|
53
|
-
"@oclif/plugin-warn-if-update-available"
|
|
49
|
+
"@oclif/plugin-not-found"
|
|
54
50
|
],
|
|
55
51
|
"hooks": {
|
|
56
|
-
"init": "./dist/hooks/init
|
|
57
|
-
"
|
|
58
|
-
"jit_plugin_not_installed": "./dist/hooks/jit-install.js",
|
|
59
|
-
"plugins:preinstall": "./dist/hooks/trust.js"
|
|
52
|
+
"init": "./dist/hooks/init.js",
|
|
53
|
+
"finally": "./dist/hooks/plugins-changed.js"
|
|
60
54
|
},
|
|
61
|
-
"
|
|
62
|
-
"
|
|
63
|
-
|
|
55
|
+
"topics": {
|
|
56
|
+
"host": {
|
|
57
|
+
"description": "The background host that warm commands use; started automatically, or start, stop, reload, and inspect it here."
|
|
58
|
+
},
|
|
59
|
+
"mcp": {
|
|
60
|
+
"description": "Run the MCP stdio relay that forwards retrieve, execute, and commit."
|
|
61
|
+
},
|
|
62
|
+
"plugins": {
|
|
63
|
+
"description": "Install and list ECP provider packages under $ECP_HOME/plugins."
|
|
64
|
+
},
|
|
65
|
+
"config": {
|
|
66
|
+
"description": "Local settings for this machine (not config objects — those use retrieve --type config and commit --type config)."
|
|
67
|
+
},
|
|
68
|
+
"config:secrets": {
|
|
69
|
+
"description": "Store secret key values in the OS keychain for $secret references (list shows keys only)."
|
|
70
|
+
}
|
|
64
71
|
}
|
|
65
72
|
},
|
|
66
73
|
"scripts": {
|
|
67
|
-
"build": "tsc -b"
|
|
68
|
-
"start": "node ./bin/dev.js"
|
|
74
|
+
"build": "tsc -b && node ../../scripts/check-oclif-manifest.mjs --write"
|
|
69
75
|
}
|
|
70
76
|
}
|
package/dist/commands.d.ts
DELETED
package/dist/commands.d.ts.map
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"commands.d.ts","sourceRoot":"","sources":["../src/commands.ts"],"names":[],"mappings":"AAGA;;;;GAIG;AACH,eAAO,MAAM,QAAQ,qDAAyB,CAAA"}
|
package/dist/commands.js
DELETED
|
@@ -1,9 +0,0 @@
|
|
|
1
|
-
import { toCommands } from "@executioncontrolprotocol/plugin-sdk";
|
|
2
|
-
import { operations } from "./operations/index.js";
|
|
3
|
-
/**
|
|
4
|
-
* CLI command classes generated from host operations.
|
|
5
|
-
* oclif loads this map with the explicit strategy.
|
|
6
|
-
* @category CLI
|
|
7
|
-
*/
|
|
8
|
-
export const COMMANDS = toCommands(operations);
|
|
9
|
-
//# sourceMappingURL=commands.js.map
|
package/dist/commands.js.map
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"commands.js","sourceRoot":"","sources":["../src/commands.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,UAAU,EAAE,MAAM,sCAAsC,CAAA;AACjE,OAAO,EAAE,UAAU,EAAE,MAAM,uBAAuB,CAAA;AAElD;;;;GAIG;AACH,MAAM,CAAC,MAAM,QAAQ,GAAG,UAAU,CAAC,UAAU,CAAC,CAAA"}
|
|
@@ -1,8 +0,0 @@
|
|
|
1
|
-
import type { Hook } from "@oclif/core";
|
|
2
|
-
/**
|
|
3
|
-
* Map an unknown topic to a first-party plugin, or redirect `ecp plugin` to `ecp plugins`.
|
|
4
|
-
* @category CLI
|
|
5
|
-
*/
|
|
6
|
-
declare const hook: Hook<"command_not_found">;
|
|
7
|
-
export default hook;
|
|
8
|
-
//# sourceMappingURL=command-not-found.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"command-not-found.d.ts","sourceRoot":"","sources":["../../src/hooks/command-not-found.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,IAAI,EAAE,MAAM,aAAa,CAAA;AAevC;;;GAGG;AACH,QAAA,MAAM,IAAI,EAAE,IAAI,CAAC,mBAAmB,CAmEnC,CAAA;AAED,eAAe,IAAI,CAAA"}
|
|
@@ -1,72 +0,0 @@
|
|
|
1
|
-
import { ECP_PLUGINS_MISSING, EXIT_PLUGINS_MISSING, failureEnvelope, } from "@executioncontrolprotocol/plugin-sdk";
|
|
2
|
-
import { argvHasFlag } from "../lib/argv.js";
|
|
3
|
-
import { confirm } from "../lib/confirm.js";
|
|
4
|
-
import { jitPluginForTopic } from "../lib/jit-plugins.js";
|
|
5
|
-
function firstToken(id) {
|
|
6
|
-
if (!id)
|
|
7
|
-
return "";
|
|
8
|
-
return id.split(":")[0] ?? id;
|
|
9
|
-
}
|
|
10
|
-
/**
|
|
11
|
-
* Map an unknown topic to a first-party plugin, or redirect `ecp plugin` to `ecp plugins`.
|
|
12
|
-
* @category CLI
|
|
13
|
-
*/
|
|
14
|
-
const hook = async function (options) {
|
|
15
|
-
const id = options.id ?? "";
|
|
16
|
-
const argv = options.argv ?? [];
|
|
17
|
-
const json = argvHasFlag(argv, "json");
|
|
18
|
-
if (id === "plugin" || id.startsWith("plugin:")) {
|
|
19
|
-
const rest = id === "plugin"
|
|
20
|
-
? argv.join(" ")
|
|
21
|
-
: `${id.slice("plugin:".length).replaceAll(":", " ")} ${argv.join(" ")}`.trim();
|
|
22
|
-
const suggestion = rest ? `ecp plugins ${rest}` : "ecp plugins";
|
|
23
|
-
const message = `The command is ${suggestion}, not ecp plugin.`;
|
|
24
|
-
if (json) {
|
|
25
|
-
this.log(JSON.stringify(failureEnvelope({
|
|
26
|
-
code: ECP_PLUGINS_MISSING,
|
|
27
|
-
message,
|
|
28
|
-
suggestions: [suggestion],
|
|
29
|
-
})));
|
|
30
|
-
}
|
|
31
|
-
else {
|
|
32
|
-
this.log(message);
|
|
33
|
-
}
|
|
34
|
-
this.exit(EXIT_PLUGINS_MISSING);
|
|
35
|
-
}
|
|
36
|
-
const topic = firstToken(id);
|
|
37
|
-
if (!topic)
|
|
38
|
-
return;
|
|
39
|
-
const jitPlugins = this.config.pjson?.oclif
|
|
40
|
-
?.jitPlugins ?? {};
|
|
41
|
-
// JIT packages (`mcp`, later `app`) are not `plugin-<topic>`. Let oclif's
|
|
42
|
-
// plugin-not-found hook install from `oclif.jitPlugins` instead of mapping
|
|
43
|
-
// `ecp mcp` to `@executioncontrolprotocol/plugin-mcp`.
|
|
44
|
-
if (jitPluginForTopic(topic, jitPlugins))
|
|
45
|
-
return;
|
|
46
|
-
// First-party plugins are unpublished until later phases. Map the unknown
|
|
47
|
-
// topic to plugin-<topic> so `ecp jsonata` returns ECP_PLUGINS_MISSING
|
|
48
|
-
// (exit 3) instead of oclif's not-found exit 127.
|
|
49
|
-
const pkg = `@executioncontrolprotocol/plugin-${topic}`;
|
|
50
|
-
const installHint = `ecp plugins install ${topic}`;
|
|
51
|
-
const message = `Plugin ${pkg} is not installed.`;
|
|
52
|
-
if (json) {
|
|
53
|
-
this.log(JSON.stringify(failureEnvelope({
|
|
54
|
-
code: ECP_PLUGINS_MISSING,
|
|
55
|
-
message,
|
|
56
|
-
suggestions: [installHint],
|
|
57
|
-
})));
|
|
58
|
-
this.exit(EXIT_PLUGINS_MISSING);
|
|
59
|
-
}
|
|
60
|
-
if (process.stdin.isTTY && process.stdout.isTTY) {
|
|
61
|
-
const ok = await confirm(`Install ${pkg} and rerun?`, argv);
|
|
62
|
-
if (ok) {
|
|
63
|
-
await this.config.runCommand("plugins:install", [pkg]);
|
|
64
|
-
await this.config.runCommand(id, argv);
|
|
65
|
-
return;
|
|
66
|
-
}
|
|
67
|
-
}
|
|
68
|
-
this.log(`${message} Run: ${installHint}`);
|
|
69
|
-
this.exit(EXIT_PLUGINS_MISSING);
|
|
70
|
-
};
|
|
71
|
-
export default hook;
|
|
72
|
-
//# sourceMappingURL=command-not-found.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"command-not-found.js","sourceRoot":"","sources":["../../src/hooks/command-not-found.ts"],"names":[],"mappings":"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"}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"init-host.d.ts","sourceRoot":"","sources":["../../src/hooks/init-host.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,IAAI,EAAc,MAAM,aAAa,CAAA;AAkCnD;;;GAGG;AACH,QAAA,MAAM,IAAI,EAAE,IAAI,CAAC,MAAM,CAYtB,CAAA;AAED,eAAe,IAAI,CAAA"}
|
package/dist/hooks/init-host.js
DELETED
|
@@ -1,45 +0,0 @@
|
|
|
1
|
-
import { NODE_ENVIRONMENT_ID, writeInvokeJournal } from "@executioncontrolprotocol/node";
|
|
2
|
-
import { setHost } from "@executioncontrolprotocol/plugin-sdk";
|
|
3
|
-
import { createProcessEnvironment } from "../lib/plugin-bindings.js";
|
|
4
|
-
async function reloadUserPlugins(config) {
|
|
5
|
-
const loader = config;
|
|
6
|
-
await loader.loadPluginsAndCommands?.({ force: true });
|
|
7
|
-
}
|
|
8
|
-
async function createHost(config) {
|
|
9
|
-
const env = await createProcessEnvironment(config);
|
|
10
|
-
const ecp = await env.init();
|
|
11
|
-
const host = {
|
|
12
|
-
ecp,
|
|
13
|
-
registry: ecp.getRegistry(),
|
|
14
|
-
environmentId: NODE_ENVIRONMENT_ID,
|
|
15
|
-
output: "pretty",
|
|
16
|
-
recordInvoke: async (entry) => {
|
|
17
|
-
await writeInvokeJournal(entry);
|
|
18
|
-
},
|
|
19
|
-
rebuild: async () => {
|
|
20
|
-
await ecp.terminate();
|
|
21
|
-
await reloadUserPlugins(config);
|
|
22
|
-
const next = await createHost(config);
|
|
23
|
-
setHost(next);
|
|
24
|
-
return next;
|
|
25
|
-
},
|
|
26
|
-
};
|
|
27
|
-
return host;
|
|
28
|
-
}
|
|
29
|
-
/**
|
|
30
|
-
* Create the process-wide ECP host from installed plugin definitions.
|
|
31
|
-
* @category CLI
|
|
32
|
-
*/
|
|
33
|
-
const hook = async function (options) {
|
|
34
|
-
const argv = options.argv ?? process.argv;
|
|
35
|
-
if (!options.id ||
|
|
36
|
-
options.id === "help" ||
|
|
37
|
-
options.id === "version" ||
|
|
38
|
-
argv.includes("--help") ||
|
|
39
|
-
argv.includes("-h")) {
|
|
40
|
-
return;
|
|
41
|
-
}
|
|
42
|
-
setHost(await createHost(options.config));
|
|
43
|
-
};
|
|
44
|
-
export default hook;
|
|
45
|
-
//# sourceMappingURL=init-host.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"init-host.js","sourceRoot":"","sources":["../../src/hooks/init-host.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,mBAAmB,EAAE,kBAAkB,EAAE,MAAM,gCAAgC,CAAA;AACxF,OAAO,EAAE,OAAO,EAAgB,MAAM,sCAAsC,CAAA;AAC5E,OAAO,EAAE,wBAAwB,EAAE,MAAM,2BAA2B,CAAA;AAEpE,KAAK,UAAU,iBAAiB,CAAC,MAAyB;IACxD,MAAM,MAAM,GAAG,MAEd,CAAA;IACD,MAAM,MAAM,CAAC,sBAAsB,EAAE,CAAC,EAAE,KAAK,EAAE,IAAI,EAAE,CAAC,CAAA;AACxD,CAAC;AAED,KAAK,UAAU,UAAU,CAAC,MAAyB;IACjD,MAAM,GAAG,GAAG,MAAM,wBAAwB,CAAC,MAAM,CAAC,CAAA;IAClD,MAAM,GAAG,GAAG,MAAM,GAAG,CAAC,IAAI,EAAE,CAAA;IAC5B,MAAM,IAAI,GAAY;QACpB,GAAG;QACH,QAAQ,EAAE,GAAG,CAAC,WAAW,EAAE;QAC3B,aAAa,EAAE,mBAAmB;QAClC,MAAM,EAAE,QAAQ;QAChB,YAAY,EAAE,KAAK,EAAE,KAAK,EAAE,EAAE;YAC5B,MAAM,kBAAkB,CAAC,KAAK,CAAC,CAAA;QACjC,CAAC;QACD,OAAO,EAAE,KAAK,IAAI,EAAE;YAClB,MAAM,GAAG,CAAC,SAAS,EAAE,CAAA;YACrB,MAAM,iBAAiB,CAAC,MAAM,CAAC,CAAA;YAC/B,MAAM,IAAI,GAAG,MAAM,UAAU,CAAC,MAAM,CAAC,CAAA;YACrC,OAAO,CAAC,IAAI,CAAC,CAAA;YACb,OAAO,IAAI,CAAA;QACb,CAAC;KACF,CAAA;IACD,OAAO,IAAI,CAAA;AACb,CAAC;AAED;;;GAGG;AACH,MAAM,IAAI,GAAiB,KAAK,WAAW,OAAO;IAChD,MAAM,IAAI,GAAG,OAAO,CAAC,IAAI,IAAI,OAAO,CAAC,IAAI,CAAA;IACzC,IACE,CAAC,OAAO,CAAC,EAAE;QACX,OAAO,CAAC,EAAE,KAAK,MAAM;QACrB,OAAO,CAAC,EAAE,KAAK,SAAS;QACxB,IAAI,CAAC,QAAQ,CAAC,QAAQ,CAAC;QACvB,IAAI,CAAC,QAAQ,CAAC,IAAI,CAAC,EACnB,CAAC;QACD,OAAM;IACR,CAAC;IACD,OAAO,CAAC,MAAM,UAAU,CAAC,OAAO,CAAC,MAAM,CAAC,CAAC,CAAA;AAC3C,CAAC,CAAA;AAED,eAAe,IAAI,CAAA"}
|
|
@@ -1,8 +0,0 @@
|
|
|
1
|
-
import type { Hook } from "@oclif/core";
|
|
2
|
-
/**
|
|
3
|
-
* Confirm, install a JIT plugin at its pinned range, then rerun the command.
|
|
4
|
-
* @category CLI
|
|
5
|
-
*/
|
|
6
|
-
declare const hook: Hook<"jit_plugin_not_installed">;
|
|
7
|
-
export default hook;
|
|
8
|
-
//# sourceMappingURL=jit-install.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"jit-install.d.ts","sourceRoot":"","sources":["../../src/hooks/jit-install.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,IAAI,EAAE,MAAM,aAAa,CAAA;AASvC;;;GAGG;AACH,QAAA,MAAM,IAAI,EAAE,IAAI,CAAC,0BAA0B,CAyB1C,CAAA;AAED,eAAe,IAAI,CAAA"}
|
|
@@ -1,32 +0,0 @@
|
|
|
1
|
-
import { ECP_PLUGINS_MISSING, EXIT_PLUGINS_MISSING, failureEnvelope, } from "@executioncontrolprotocol/plugin-sdk";
|
|
2
|
-
import { argvHasFlag } from "../lib/argv.js";
|
|
3
|
-
import { confirm } from "../lib/confirm.js";
|
|
4
|
-
/**
|
|
5
|
-
* Confirm, install a JIT plugin at its pinned range, then rerun the command.
|
|
6
|
-
* @category CLI
|
|
7
|
-
*/
|
|
8
|
-
const hook = async function (options) {
|
|
9
|
-
const name = options.pluginName;
|
|
10
|
-
const tag = options.pluginVersion || "latest";
|
|
11
|
-
if (!name)
|
|
12
|
-
return;
|
|
13
|
-
const spec = `${name}@${tag}`;
|
|
14
|
-
const argv = process.argv.slice(2);
|
|
15
|
-
const json = argvHasFlag(argv, "json");
|
|
16
|
-
if (json) {
|
|
17
|
-
this.log(JSON.stringify(failureEnvelope({
|
|
18
|
-
code: ECP_PLUGINS_MISSING,
|
|
19
|
-
message: `Plugin ${spec} is not installed.`,
|
|
20
|
-
suggestions: [`ecp plugins install ${spec}`],
|
|
21
|
-
})));
|
|
22
|
-
this.exit(EXIT_PLUGINS_MISSING);
|
|
23
|
-
}
|
|
24
|
-
const ok = await confirm(`Install ${spec} and continue?`, argv);
|
|
25
|
-
if (!ok) {
|
|
26
|
-
this.log(`Run: ecp plugins install ${spec}`);
|
|
27
|
-
this.exit(EXIT_PLUGINS_MISSING);
|
|
28
|
-
}
|
|
29
|
-
await this.config.runCommand("plugins:install", [spec]);
|
|
30
|
-
};
|
|
31
|
-
export default hook;
|
|
32
|
-
//# sourceMappingURL=jit-install.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"jit-install.js","sourceRoot":"","sources":["../../src/hooks/jit-install.ts"],"names":[],"mappings":"AACA,OAAO,EACL,mBAAmB,EACnB,oBAAoB,EACpB,eAAe,GAChB,MAAM,sCAAsC,CAAA;AAC7C,OAAO,EAAE,WAAW,EAAE,MAAM,gBAAgB,CAAA;AAC5C,OAAO,EAAE,OAAO,EAAE,MAAM,mBAAmB,CAAA;AAE3C;;;GAGG;AACH,MAAM,IAAI,GAAqC,KAAK,WAAW,OAAO;IACpE,MAAM,IAAI,GAAG,OAAO,CAAC,UAAU,CAAA;IAC/B,MAAM,GAAG,GAAG,OAAO,CAAC,aAAa,IAAI,QAAQ,CAAA;IAC7C,IAAI,CAAC,IAAI;QAAE,OAAM;IACjB,MAAM,IAAI,GAAG,GAAG,IAAI,IAAI,GAAG,EAAE,CAAA;IAC7B,MAAM,IAAI,GAAG,OAAO,CAAC,IAAI,CAAC,KAAK,CAAC,CAAC,CAAC,CAAA;IAClC,MAAM,IAAI,GAAG,WAAW,CAAC,IAAI,EAAE,MAAM,CAAC,CAAA;IACtC,IAAI,IAAI,EAAE,CAAC;QACT,IAAI,CAAC,GAAG,CACN,IAAI,CAAC,SAAS,CACZ,eAAe,CAAC;YACd,IAAI,EAAE,mBAAmB;YACzB,OAAO,EAAE,UAAU,IAAI,oBAAoB;YAC3C,WAAW,EAAE,CAAC,uBAAuB,IAAI,EAAE,CAAC;SAC7C,CAAC,CACH,CACF,CAAA;QACD,IAAI,CAAC,IAAI,CAAC,oBAAoB,CAAC,CAAA;IACjC,CAAC;IACD,MAAM,EAAE,GAAG,MAAM,OAAO,CAAC,WAAW,IAAI,gBAAgB,EAAE,IAAI,CAAC,CAAA;IAC/D,IAAI,CAAC,EAAE,EAAE,CAAC;QACR,IAAI,CAAC,GAAG,CAAC,4BAA4B,IAAI,EAAE,CAAC,CAAA;QAC5C,IAAI,CAAC,IAAI,CAAC,oBAAoB,CAAC,CAAA;IACjC,CAAC;IACD,MAAM,IAAI,CAAC,MAAM,CAAC,UAAU,CAAC,iBAAiB,EAAE,CAAC,IAAI,CAAC,CAAC,CAAA;AACzD,CAAC,CAAA;AAED,eAAe,IAAI,CAAA"}
|
package/dist/hooks/trust.d.ts
DELETED
|
@@ -1,9 +0,0 @@
|
|
|
1
|
-
import type { Hook } from "@oclif/core";
|
|
2
|
-
/**
|
|
3
|
-
* Trust check before `plugins:install`. First-party npm packages are allowed;
|
|
4
|
-
* third-party packages need a prompt, `--yes`, or a remembered decision.
|
|
5
|
-
* @category CLI
|
|
6
|
-
*/
|
|
7
|
-
declare const hook: Hook<"plugins:preinstall">;
|
|
8
|
-
export default hook;
|
|
9
|
-
//# sourceMappingURL=trust.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"trust.d.ts","sourceRoot":"","sources":["../../src/hooks/trust.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,IAAI,EAAE,MAAM,aAAa,CAAA;AAUvC;;;;GAIG;AACH,QAAA,MAAM,IAAI,EAAE,IAAI,CAAC,oBAAoB,CAiBpC,CAAA;AAED,eAAe,IAAI,CAAA"}
|
package/dist/hooks/trust.js
DELETED
|
@@ -1,32 +0,0 @@
|
|
|
1
|
-
import { failureEnvelope } from "@executioncontrolprotocol/plugin-sdk";
|
|
2
|
-
import { EcpCliError } from "@executioncontrolprotocol/plugin-sdk";
|
|
3
|
-
import { argvHasFlag } from "../lib/argv.js";
|
|
4
|
-
import { assertTrusted } from "../lib/evaluate-trust.js";
|
|
5
|
-
/**
|
|
6
|
-
* Trust check before `plugins:install`. First-party npm packages are allowed;
|
|
7
|
-
* third-party packages need a prompt, `--yes`, or a remembered decision.
|
|
8
|
-
* @category CLI
|
|
9
|
-
*/
|
|
10
|
-
const hook = async function (options) {
|
|
11
|
-
const plugin = options.plugin;
|
|
12
|
-
const spec = plugin?.url || plugin?.name;
|
|
13
|
-
if (!spec)
|
|
14
|
-
return;
|
|
15
|
-
try {
|
|
16
|
-
await assertTrusted(this.config, spec, process.argv.slice(2));
|
|
17
|
-
}
|
|
18
|
-
catch (err) {
|
|
19
|
-
if (err instanceof EcpCliError) {
|
|
20
|
-
if (argvHasFlag(process.argv, "json")) {
|
|
21
|
-
this.log(JSON.stringify(failureEnvelope(err.toBody())));
|
|
22
|
-
}
|
|
23
|
-
else {
|
|
24
|
-
this.error(err.message, { exit: err.exitCode });
|
|
25
|
-
}
|
|
26
|
-
this.exit(err.exitCode);
|
|
27
|
-
}
|
|
28
|
-
throw err;
|
|
29
|
-
}
|
|
30
|
-
};
|
|
31
|
-
export default hook;
|
|
32
|
-
//# sourceMappingURL=trust.js.map
|
package/dist/hooks/trust.js.map
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"trust.js","sourceRoot":"","sources":["../../src/hooks/trust.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,eAAe,EAAE,MAAM,sCAAsC,CAAA;AACtE,OAAO,EAAE,WAAW,EAAE,MAAM,sCAAsC,CAAA;AAClE,OAAO,EAAE,WAAW,EAAE,MAAM,gBAAgB,CAAA;AAC5C,OAAO,EAAE,aAAa,EAAE,MAAM,0BAA0B,CAAA;AAMxD;;;;GAIG;AACH,MAAM,IAAI,GAA+B,KAAK,WAAW,OAAO;IAC9D,MAAM,MAAM,GAAI,OAAwC,CAAC,MAAM,CAAA;IAC/D,MAAM,IAAI,GAAG,MAAM,EAAE,GAAG,IAAI,MAAM,EAAE,IAAI,CAAA;IACxC,IAAI,CAAC,IAAI;QAAE,OAAM;IACjB,IAAI,CAAC;QACH,MAAM,aAAa,CAAC,IAAI,CAAC,MAAM,EAAE,IAAI,EAAE,OAAO,CAAC,IAAI,CAAC,KAAK,CAAC,CAAC,CAAC,CAAC,CAAA;IAC/D,CAAC;IAAC,OAAO,GAAG,EAAE,CAAC;QACb,IAAI,GAAG,YAAY,WAAW,EAAE,CAAC;YAC/B,IAAI,WAAW,CAAC,OAAO,CAAC,IAAI,EAAE,MAAM,CAAC,EAAE,CAAC;gBACtC,IAAI,CAAC,GAAG,CAAC,IAAI,CAAC,SAAS,CAAC,eAAe,CAAC,GAAG,CAAC,MAAM,EAAE,CAAC,CAAC,CAAC,CAAA;YACzD,CAAC;iBAAM,CAAC;gBACN,IAAI,CAAC,KAAK,CAAC,GAAG,CAAC,OAAO,EAAE,EAAE,IAAI,EAAE,GAAG,CAAC,QAAQ,EAAE,CAAC,CAAA;YACjD,CAAC;YACD,IAAI,CAAC,IAAI,CAAC,GAAG,CAAC,QAAQ,CAAC,CAAA;QACzB,CAAC;QACD,MAAM,GAAG,CAAA;IACX,CAAC;AACH,CAAC,CAAA;AAED,eAAe,IAAI,CAAA"}
|
package/dist/lib/argv.d.ts
DELETED
|
@@ -1,11 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* True when argv includes `--name`, `--name=…`, or `-x` for a known short flag.
|
|
3
|
-
* @category CLI
|
|
4
|
-
*/
|
|
5
|
-
export declare function argvHasFlag(argv: string[], name: string, short?: string): boolean;
|
|
6
|
-
/**
|
|
7
|
-
* Value of `--name <value>` or `--name=value` from argv.
|
|
8
|
-
* @category CLI
|
|
9
|
-
*/
|
|
10
|
-
export declare function argvFlagValue(argv: string[], name: string): string | undefined;
|
|
11
|
-
//# sourceMappingURL=argv.d.ts.map
|
package/dist/lib/argv.d.ts.map
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"argv.d.ts","sourceRoot":"","sources":["../../src/lib/argv.ts"],"names":[],"mappings":"AAAA;;;GAGG;AACH,wBAAgB,WAAW,CAAC,IAAI,EAAE,MAAM,EAAE,EAAE,IAAI,EAAE,MAAM,EAAE,KAAK,CAAC,EAAE,MAAM,GAAG,OAAO,CAKjF;AAED;;;GAGG;AACH,wBAAgB,aAAa,CAAC,IAAI,EAAE,MAAM,EAAE,EAAE,IAAI,EAAE,MAAM,GAAG,MAAM,GAAG,SAAS,CAS9E"}
|
package/dist/lib/argv.js
DELETED
|
@@ -1,30 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* True when argv includes `--name`, `--name=…`, or `-x` for a known short flag.
|
|
3
|
-
* @category CLI
|
|
4
|
-
*/
|
|
5
|
-
export function argvHasFlag(argv, name, short) {
|
|
6
|
-
const token = `--${name}`;
|
|
7
|
-
if (argv.some((arg) => arg === token || arg.startsWith(`${token}=`)))
|
|
8
|
-
return true;
|
|
9
|
-
if (short && argv.includes(`-${short}`))
|
|
10
|
-
return true;
|
|
11
|
-
return false;
|
|
12
|
-
}
|
|
13
|
-
/**
|
|
14
|
-
* Value of `--name <value>` or `--name=value` from argv.
|
|
15
|
-
* @category CLI
|
|
16
|
-
*/
|
|
17
|
-
export function argvFlagValue(argv, name) {
|
|
18
|
-
const token = `--${name}`;
|
|
19
|
-
for (let i = 0; i < argv.length; i += 1) {
|
|
20
|
-
const arg = argv[i];
|
|
21
|
-
if (!arg)
|
|
22
|
-
continue;
|
|
23
|
-
if (arg === token)
|
|
24
|
-
return argv[i + 1];
|
|
25
|
-
if (arg.startsWith(`${token}=`))
|
|
26
|
-
return arg.slice(token.length + 1);
|
|
27
|
-
}
|
|
28
|
-
return undefined;
|
|
29
|
-
}
|
|
30
|
-
//# sourceMappingURL=argv.js.map
|
package/dist/lib/argv.js.map
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"argv.js","sourceRoot":"","sources":["../../src/lib/argv.ts"],"names":[],"mappings":"AAAA;;;GAGG;AACH,MAAM,UAAU,WAAW,CAAC,IAAc,EAAE,IAAY,EAAE,KAAc;IACtE,MAAM,KAAK,GAAG,KAAK,IAAI,EAAE,CAAA;IACzB,IAAI,IAAI,CAAC,IAAI,CAAC,CAAC,GAAG,EAAE,EAAE,CAAC,GAAG,KAAK,KAAK,IAAI,GAAG,CAAC,UAAU,CAAC,GAAG,KAAK,GAAG,CAAC,CAAC;QAAE,OAAO,IAAI,CAAA;IACjF,IAAI,KAAK,IAAI,IAAI,CAAC,QAAQ,CAAC,IAAI,KAAK,EAAE,CAAC;QAAE,OAAO,IAAI,CAAA;IACpD,OAAO,KAAK,CAAA;AACd,CAAC;AAED;;;GAGG;AACH,MAAM,UAAU,aAAa,CAAC,IAAc,EAAE,IAAY;IACxD,MAAM,KAAK,GAAG,KAAK,IAAI,EAAE,CAAA;IACzB,KAAK,IAAI,CAAC,GAAG,CAAC,EAAE,CAAC,GAAG,IAAI,CAAC,MAAM,EAAE,CAAC,IAAI,CAAC,EAAE,CAAC;QACxC,MAAM,GAAG,GAAG,IAAI,CAAC,CAAC,CAAC,CAAA;QACnB,IAAI,CAAC,GAAG;YAAE,SAAQ;QAClB,IAAI,GAAG,KAAK,KAAK;YAAE,OAAO,IAAI,CAAC,CAAC,GAAG,CAAC,CAAC,CAAA;QACrC,IAAI,GAAG,CAAC,UAAU,CAAC,GAAG,KAAK,GAAG,CAAC;YAAE,OAAO,GAAG,CAAC,KAAK,CAAC,KAAK,CAAC,MAAM,GAAG,CAAC,CAAC,CAAA;IACrE,CAAC;IACD,OAAO,SAAS,CAAA;AAClB,CAAC"}
|
|
@@ -1,14 +0,0 @@
|
|
|
1
|
-
import type { Command } from "@oclif/core";
|
|
2
|
-
/** Format thrown values for CLI error output. */
|
|
3
|
-
export declare function commandErrorMessage(err: unknown): string;
|
|
4
|
-
/**
|
|
5
|
-
* Read and parse a JSON file, mapping read/parse failures to an actionable,
|
|
6
|
-
* flag-attributed error message (e.g. `--input: invalid JSON in "x.json"`).
|
|
7
|
-
*/
|
|
8
|
-
export declare function readJsonFile<T = unknown>(path: string, flagName: string): Promise<T>;
|
|
9
|
-
/**
|
|
10
|
-
* Runs `fn` and maps any thrown value to `cmd.error` with exit code 1.
|
|
11
|
-
* Use after `parse()` so flag validation errors are not swallowed.
|
|
12
|
-
*/
|
|
13
|
-
export declare function runWithCommandError(cmd: Command, fn: () => void | Promise<void>): Promise<void>;
|
|
14
|
-
//# sourceMappingURL=command-helpers.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"command-helpers.d.ts","sourceRoot":"","sources":["../../src/lib/command-helpers.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,OAAO,EAAE,MAAM,aAAa,CAAA;AAG1C,iDAAiD;AACjD,wBAAgB,mBAAmB,CAAC,GAAG,EAAE,OAAO,GAAG,MAAM,CAExD;AAED;;;GAGG;AACH,wBAAsB,YAAY,CAAC,CAAC,GAAG,OAAO,EAC5C,IAAI,EAAE,MAAM,EACZ,QAAQ,EAAE,MAAM,GACf,OAAO,CAAC,CAAC,CAAC,CAcZ;AAED;;;GAGG;AACH,wBAAsB,mBAAmB,CACvC,GAAG,EAAE,OAAO,EACZ,EAAE,EAAE,MAAM,IAAI,GAAG,OAAO,CAAC,IAAI,CAAC,GAC7B,OAAO,CAAC,IAAI,CAAC,CAMf"}
|
|
@@ -1,37 +0,0 @@
|
|
|
1
|
-
import { readFile } from "node:fs/promises";
|
|
2
|
-
/** Format thrown values for CLI error output. */
|
|
3
|
-
export function commandErrorMessage(err) {
|
|
4
|
-
return err instanceof Error ? err.message : String(err);
|
|
5
|
-
}
|
|
6
|
-
/**
|
|
7
|
-
* Read and parse a JSON file, mapping read/parse failures to an actionable,
|
|
8
|
-
* flag-attributed error message (e.g. `--input: invalid JSON in "x.json"`).
|
|
9
|
-
*/
|
|
10
|
-
export async function readJsonFile(path, flagName) {
|
|
11
|
-
let raw;
|
|
12
|
-
try {
|
|
13
|
-
raw = await readFile(path, "utf8");
|
|
14
|
-
}
|
|
15
|
-
catch {
|
|
16
|
-
throw new Error(`${flagName}: cannot read file "${path}"`);
|
|
17
|
-
}
|
|
18
|
-
try {
|
|
19
|
-
return JSON.parse(raw);
|
|
20
|
-
}
|
|
21
|
-
catch (err) {
|
|
22
|
-
throw new Error(`${flagName}: invalid JSON in "${path}" (${commandErrorMessage(err)})`);
|
|
23
|
-
}
|
|
24
|
-
}
|
|
25
|
-
/**
|
|
26
|
-
* Runs `fn` and maps any thrown value to `cmd.error` with exit code 1.
|
|
27
|
-
* Use after `parse()` so flag validation errors are not swallowed.
|
|
28
|
-
*/
|
|
29
|
-
export async function runWithCommandError(cmd, fn) {
|
|
30
|
-
try {
|
|
31
|
-
await fn();
|
|
32
|
-
}
|
|
33
|
-
catch (err) {
|
|
34
|
-
cmd.error(commandErrorMessage(err), { exit: 1 });
|
|
35
|
-
}
|
|
36
|
-
}
|
|
37
|
-
//# sourceMappingURL=command-helpers.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"command-helpers.js","sourceRoot":"","sources":["../../src/lib/command-helpers.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,QAAQ,EAAE,MAAM,kBAAkB,CAAA;AAE3C,iDAAiD;AACjD,MAAM,UAAU,mBAAmB,CAAC,GAAY;IAC9C,OAAO,GAAG,YAAY,KAAK,CAAC,CAAC,CAAC,GAAG,CAAC,OAAO,CAAC,CAAC,CAAC,MAAM,CAAC,GAAG,CAAC,CAAA;AACzD,CAAC;AAED;;;GAGG;AACH,MAAM,CAAC,KAAK,UAAU,YAAY,CAChC,IAAY,EACZ,QAAgB;IAEhB,IAAI,GAAW,CAAA;IACf,IAAI,CAAC;QACH,GAAG,GAAG,MAAM,QAAQ,CAAC,IAAI,EAAE,MAAM,CAAC,CAAA;IACpC,CAAC;IAAC,MAAM,CAAC;QACP,MAAM,IAAI,KAAK,CAAC,GAAG,QAAQ,uBAAuB,IAAI,GAAG,CAAC,CAAA;IAC5D,CAAC;IACD,IAAI,CAAC;QACH,OAAO,IAAI,CAAC,KAAK,CAAC,GAAG,CAAM,CAAA;IAC7B,CAAC;IAAC,OAAO,GAAG,EAAE,CAAC;QACb,MAAM,IAAI,KAAK,CACb,GAAG,QAAQ,sBAAsB,IAAI,MAAM,mBAAmB,CAAC,GAAG,CAAC,GAAG,CACvE,CAAA;IACH,CAAC;AACH,CAAC;AAED;;;GAGG;AACH,MAAM,CAAC,KAAK,UAAU,mBAAmB,CACvC,GAAY,EACZ,EAA8B;IAE9B,IAAI,CAAC;QACH,MAAM,EAAE,EAAE,CAAA;IACZ,CAAC;IAAC,OAAO,GAAG,EAAE,CAAC;QACb,GAAG,CAAC,KAAK,CAAC,mBAAmB,CAAC,GAAG,CAAC,EAAE,EAAE,IAAI,EAAE,CAAC,EAAE,CAAC,CAAA;IAClD,CAAC;AACH,CAAC"}
|
package/dist/lib/confirm.d.ts
DELETED
|
@@ -1,16 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* True when the user passed `--yes` or `ECP_TRUST_THIRD_PARTY=1`.
|
|
3
|
-
* @category CLI
|
|
4
|
-
*/
|
|
5
|
-
export declare function wantsYes(argv?: string[]): boolean;
|
|
6
|
-
/**
|
|
7
|
-
* Confirm an action: `--yes` wins; otherwise prompt on a TTY.
|
|
8
|
-
* @category CLI
|
|
9
|
-
*/
|
|
10
|
-
export declare function confirm(message: string, argv?: string[]): Promise<boolean>;
|
|
11
|
-
/**
|
|
12
|
-
* Confirm an install: `--yes` wins; empty TTY answer defaults to yes.
|
|
13
|
-
* @category CLI
|
|
14
|
-
*/
|
|
15
|
-
export declare function confirmDefaultYes(message: string, argv?: string[]): Promise<boolean>;
|
|
16
|
-
//# sourceMappingURL=confirm.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"confirm.d.ts","sourceRoot":"","sources":["../../src/lib/confirm.ts"],"names":[],"mappings":"AAIA;;;GAGG;AACH,wBAAgB,QAAQ,CAAC,IAAI,GAAE,MAAM,EAAiB,GAAG,OAAO,CAE/D;AAED;;;GAGG;AACH,wBAAsB,OAAO,CAAC,OAAO,EAAE,MAAM,EAAE,IAAI,GAAE,MAAM,EAAiB,GAAG,OAAO,CAAC,OAAO,CAAC,CAU9F;AAED;;;GAGG;AACH,wBAAsB,iBAAiB,CACrC,OAAO,EAAE,MAAM,EACf,IAAI,GAAE,MAAM,EAAiB,GAC5B,OAAO,CAAC,OAAO,CAAC,CAWlB"}
|
package/dist/lib/confirm.js
DELETED
|
@@ -1,49 +0,0 @@
|
|
|
1
|
-
import { createInterface } from "node:readline/promises";
|
|
2
|
-
import { stdin as input, stdout as output } from "node:process";
|
|
3
|
-
import { argvHasFlag } from "./argv.js";
|
|
4
|
-
/**
|
|
5
|
-
* True when the user passed `--yes` or `ECP_TRUST_THIRD_PARTY=1`.
|
|
6
|
-
* @category CLI
|
|
7
|
-
*/
|
|
8
|
-
export function wantsYes(argv = process.argv) {
|
|
9
|
-
return argvHasFlag(argv, "yes") || process.env.ECP_TRUST_THIRD_PARTY === "1";
|
|
10
|
-
}
|
|
11
|
-
/**
|
|
12
|
-
* Confirm an action: `--yes` wins; otherwise prompt on a TTY.
|
|
13
|
-
* @category CLI
|
|
14
|
-
*/
|
|
15
|
-
export async function confirm(message, argv = process.argv) {
|
|
16
|
-
if (wantsYes(argv))
|
|
17
|
-
return true;
|
|
18
|
-
if (!process.stdin.isTTY || !process.stdout.isTTY)
|
|
19
|
-
return false;
|
|
20
|
-
const rl = createInterface({ input, output });
|
|
21
|
-
try {
|
|
22
|
-
const answer = (await rl.question(`${message} (y/N) `)).trim().toLowerCase();
|
|
23
|
-
return answer === "y" || answer === "yes";
|
|
24
|
-
}
|
|
25
|
-
finally {
|
|
26
|
-
rl.close();
|
|
27
|
-
}
|
|
28
|
-
}
|
|
29
|
-
/**
|
|
30
|
-
* Confirm an install: `--yes` wins; empty TTY answer defaults to yes.
|
|
31
|
-
* @category CLI
|
|
32
|
-
*/
|
|
33
|
-
export async function confirmDefaultYes(message, argv = process.argv) {
|
|
34
|
-
if (wantsYes(argv))
|
|
35
|
-
return true;
|
|
36
|
-
if (!process.stdin.isTTY || !process.stdout.isTTY)
|
|
37
|
-
return false;
|
|
38
|
-
const rl = createInterface({ input, output });
|
|
39
|
-
try {
|
|
40
|
-
const answer = (await rl.question(`${message} (Y/n) `)).trim().toLowerCase();
|
|
41
|
-
if (answer === "")
|
|
42
|
-
return true;
|
|
43
|
-
return answer === "y" || answer === "yes";
|
|
44
|
-
}
|
|
45
|
-
finally {
|
|
46
|
-
rl.close();
|
|
47
|
-
}
|
|
48
|
-
}
|
|
49
|
-
//# sourceMappingURL=confirm.js.map
|
package/dist/lib/confirm.js.map
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"confirm.js","sourceRoot":"","sources":["../../src/lib/confirm.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,eAAe,EAAE,MAAM,wBAAwB,CAAA;AACxD,OAAO,EAAE,KAAK,IAAI,KAAK,EAAE,MAAM,IAAI,MAAM,EAAE,MAAM,cAAc,CAAA;AAC/D,OAAO,EAAE,WAAW,EAAE,MAAM,WAAW,CAAA;AAEvC;;;GAGG;AACH,MAAM,UAAU,QAAQ,CAAC,OAAiB,OAAO,CAAC,IAAI;IACpD,OAAO,WAAW,CAAC,IAAI,EAAE,KAAK,CAAC,IAAI,OAAO,CAAC,GAAG,CAAC,qBAAqB,KAAK,GAAG,CAAA;AAC9E,CAAC;AAED;;;GAGG;AACH,MAAM,CAAC,KAAK,UAAU,OAAO,CAAC,OAAe,EAAE,OAAiB,OAAO,CAAC,IAAI;IAC1E,IAAI,QAAQ,CAAC,IAAI,CAAC;QAAE,OAAO,IAAI,CAAA;IAC/B,IAAI,CAAC,OAAO,CAAC,KAAK,CAAC,KAAK,IAAI,CAAC,OAAO,CAAC,MAAM,CAAC,KAAK;QAAE,OAAO,KAAK,CAAA;IAC/D,MAAM,EAAE,GAAG,eAAe,CAAC,EAAE,KAAK,EAAE,MAAM,EAAE,CAAC,CAAA;IAC7C,IAAI,CAAC;QACH,MAAM,MAAM,GAAG,CAAC,MAAM,EAAE,CAAC,QAAQ,CAAC,GAAG,OAAO,SAAS,CAAC,CAAC,CAAC,IAAI,EAAE,CAAC,WAAW,EAAE,CAAA;QAC5E,OAAO,MAAM,KAAK,GAAG,IAAI,MAAM,KAAK,KAAK,CAAA;IAC3C,CAAC;YAAS,CAAC;QACT,EAAE,CAAC,KAAK,EAAE,CAAA;IACZ,CAAC;AACH,CAAC;AAED;;;GAGG;AACH,MAAM,CAAC,KAAK,UAAU,iBAAiB,CACrC,OAAe,EACf,OAAiB,OAAO,CAAC,IAAI;IAE7B,IAAI,QAAQ,CAAC,IAAI,CAAC;QAAE,OAAO,IAAI,CAAA;IAC/B,IAAI,CAAC,OAAO,CAAC,KAAK,CAAC,KAAK,IAAI,CAAC,OAAO,CAAC,MAAM,CAAC,KAAK;QAAE,OAAO,KAAK,CAAA;IAC/D,MAAM,EAAE,GAAG,eAAe,CAAC,EAAE,KAAK,EAAE,MAAM,EAAE,CAAC,CAAA;IAC7C,IAAI,CAAC;QACH,MAAM,MAAM,GAAG,CAAC,MAAM,EAAE,CAAC,QAAQ,CAAC,GAAG,OAAO,SAAS,CAAC,CAAC,CAAC,IAAI,EAAE,CAAC,WAAW,EAAE,CAAA;QAC5E,IAAI,MAAM,KAAK,EAAE;YAAE,OAAO,IAAI,CAAA;QAC9B,OAAO,MAAM,KAAK,GAAG,IAAI,MAAM,KAAK,KAAK,CAAA;IAC3C,CAAC;YAAS,CAAC;QACT,EAAE,CAAC,KAAK,EAAE,CAAA;IACZ,CAAC;AACH,CAAC"}
|
|
@@ -1,17 +0,0 @@
|
|
|
1
|
-
import type { Interfaces } from "@oclif/core";
|
|
2
|
-
import type { RequirementsDocument } from "@executioncontrolprotocol/core";
|
|
3
|
-
import { type EcpHost } from "@executioncontrolprotocol/plugin-sdk";
|
|
4
|
-
/**
|
|
5
|
-
* Ensure required plugins are installed. `validate` never installs.
|
|
6
|
-
* Interactive run prompts per package; `--json` / non-TTY throw {@link ECP_PLUGINS_MISSING}.
|
|
7
|
-
* @category CLI
|
|
8
|
-
*/
|
|
9
|
-
export declare function ensurePluginsInstalled(options: {
|
|
10
|
-
requirements: RequirementsDocument;
|
|
11
|
-
config: Interfaces.Config;
|
|
12
|
-
argv: string[];
|
|
13
|
-
json: boolean;
|
|
14
|
-
install: boolean;
|
|
15
|
-
host?: EcpHost;
|
|
16
|
-
}): Promise<EcpHost | undefined>;
|
|
17
|
-
//# sourceMappingURL=ensure-plugins.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"ensure-plugins.d.ts","sourceRoot":"","sources":["../../src/lib/ensure-plugins.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,aAAa,CAAA;AAC7C,OAAO,KAAK,EAAE,oBAAoB,EAAE,MAAM,gCAAgC,CAAA;AAC1E,OAAO,EAIL,KAAK,OAAO,EACb,MAAM,sCAAsC,CAAA;AAiB7C;;;;GAIG;AACH,wBAAsB,sBAAsB,CAAC,OAAO,EAAE;IACpD,YAAY,EAAE,oBAAoB,CAAA;IAClC,MAAM,EAAE,UAAU,CAAC,MAAM,CAAA;IACzB,IAAI,EAAE,MAAM,EAAE,CAAA;IACd,IAAI,EAAE,OAAO,CAAA;IACb,OAAO,EAAE,OAAO,CAAA;IAChB,IAAI,CAAC,EAAE,OAAO,CAAA;CACf,GAAG,OAAO,CAAC,OAAO,GAAG,SAAS,CAAC,CAiB/B"}
|