@rogatio/cli 1.9.1 → 2.0.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 +4 -4
- package/dist/node/index.js +26 -24
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -39,8 +39,8 @@ rogatio <command> [options]
|
|
|
39
39
|
| `rogatio edit [path]` | Launch the browser editor for `.rogatio.json`. |
|
|
40
40
|
| `rogatio verify [path]` | Validate a `.rogatio.json` file (schema + compiler). |
|
|
41
41
|
| `rogatio test [path] [url...]` | Run offline dry-run tests against `.rogatio.json`. |
|
|
42
|
-
| `rogatio runtime <
|
|
43
|
-
| `rogatio runtime
|
|
42
|
+
| `rogatio runtime <activate\|deactivate\|status\|install\|trust\|untrust\|uninstall>` | Control the native messaging runtime and request-body trust. |
|
|
43
|
+
| `rogatio runtime host <path>` | Run the consolidated native-messaging host for the project (mock/pair/authorize over stdio). Normally launched by the browser; run manually only for debugging. |
|
|
44
44
|
|
|
45
45
|
Global options: `--help, -h` and `--version, -v`. Run `rogatio <command> --help`
|
|
46
46
|
for command-specific usage.
|
|
@@ -57,8 +57,8 @@ rogatio verify .rogatio.json
|
|
|
57
57
|
# Dry-run rules against a set of URLs
|
|
58
58
|
rogatio test .rogatio.json https://example.com/ https://example.com/app.js
|
|
59
59
|
|
|
60
|
-
#
|
|
61
|
-
rogatio runtime
|
|
60
|
+
# Run the native-messaging host for the project (normally launched by the browser)
|
|
61
|
+
rogatio runtime host .rogatio.json
|
|
62
62
|
```
|
|
63
63
|
|
|
64
64
|
## Exit codes
|
package/dist/node/index.js
CHANGED
|
@@ -5971,8 +5971,8 @@ function showRuntimeHelp() {
|
|
|
5971
5971
|
Native messaging runtime control for response-body and request-body rules.
|
|
5972
5972
|
|
|
5973
5973
|
Native runtime commands:
|
|
5974
|
-
|
|
5975
|
-
|
|
5974
|
+
activate Activate the runtime (explicit, no auto-activation)
|
|
5975
|
+
deactivate Deactivate the runtime (idempotent)
|
|
5976
5976
|
status Show the current runtime and trust state
|
|
5977
5977
|
|
|
5978
5978
|
Request-body trust commands:
|
|
@@ -5983,10 +5983,10 @@ Request-body trust commands:
|
|
|
5983
5983
|
uninstall Uninstall the native-messaging host manifest (idempotent)
|
|
5984
5984
|
|
|
5985
5985
|
Native host command:
|
|
5986
|
-
|
|
5987
|
-
|
|
5988
|
-
|
|
5989
|
-
|
|
5986
|
+
host [path] Run the consolidated native-messaging runtime host, reading
|
|
5987
|
+
pairing/authorization/mock envelopes from stdin and writing
|
|
5988
|
+
responses to stdout. This process is what the browser launches
|
|
5989
|
+
via the native-messaging manifest.
|
|
5990
5990
|
|
|
5991
5991
|
Options:
|
|
5992
5992
|
--extension-id Extension ID for native messaging manifest (required for install)
|
|
@@ -6046,16 +6046,16 @@ async function nativeRuntimeCommand(args) {
|
|
|
6046
6046
|
preset: await loadControlPreset()
|
|
6047
6047
|
});
|
|
6048
6048
|
switch (subcommand) {
|
|
6049
|
-
case "
|
|
6049
|
+
case "activate": {
|
|
6050
6050
|
const result = await controller.start();
|
|
6051
6051
|
if (result.state === "running") {
|
|
6052
|
-
console.log("runtime
|
|
6052
|
+
console.log("runtime activated");
|
|
6053
6053
|
return 0;
|
|
6054
6054
|
}
|
|
6055
|
-
console.error(`runtime
|
|
6055
|
+
console.error(`runtime activate failed: ${result.state}`);
|
|
6056
6056
|
return 1;
|
|
6057
6057
|
}
|
|
6058
|
-
case "
|
|
6058
|
+
case "deactivate": {
|
|
6059
6059
|
const result = await controller.stop();
|
|
6060
6060
|
console.log(`runtime ${result.state}`);
|
|
6061
6061
|
return 0;
|
|
@@ -6276,10 +6276,11 @@ async function runtimeCommand(args, _options = {}) {
|
|
|
6276
6276
|
if (first === "install" || first === "trust" || first === "untrust" || first === "uninstall")
|
|
6277
6277
|
return trustRuntimeCommand(args);
|
|
6278
6278
|
if (first === "status") return runtimeStatusCommand(args);
|
|
6279
|
-
if (first === "
|
|
6280
|
-
|
|
6279
|
+
if (first === "activate" || first === "deactivate")
|
|
6280
|
+
return nativeRuntimeCommand(args);
|
|
6281
|
+
if (first === "host") return runtimeHostCommand(args.slice(1));
|
|
6281
6282
|
console.error(
|
|
6282
|
-
`Error: 'rogatio runtime' no longer starts an HTTP mock server. Use 'rogatio runtime
|
|
6283
|
+
`Error: 'rogatio runtime' no longer starts an HTTP mock server. Use 'rogatio runtime host [path]' to run the native-messaging host, or one of: activate, deactivate, status, install, trust, untrust, uninstall.`
|
|
6283
6284
|
);
|
|
6284
6285
|
showRuntimeHelp();
|
|
6285
6286
|
return 2;
|
|
@@ -6807,8 +6808,8 @@ Commands:
|
|
|
6807
6808
|
edit [path] Launch browser editor for .rogatio.json
|
|
6808
6809
|
test [path] [url...] Run offline dry-run tests against .rogatio.json
|
|
6809
6810
|
verify [path] Validate .rogatio.json file
|
|
6810
|
-
runtime <
|
|
6811
|
-
runtime
|
|
6811
|
+
runtime <activate|deactivate|status|install|trust|untrust|uninstall> Native messaging runtime activation and request-body trust control
|
|
6812
|
+
runtime host [path] Run the consolidated native-messaging runtime host
|
|
6812
6813
|
|
|
6813
6814
|
Global Options:
|
|
6814
6815
|
--help, -h Show help
|
|
@@ -6852,16 +6853,17 @@ Exit codes:
|
|
|
6852
6853
|
}
|
|
6853
6854
|
function showRuntimeHelp2() {
|
|
6854
6855
|
console.log(`Usage: rogatio runtime <command> [options]
|
|
6855
|
-
rogatio runtime
|
|
6856
|
+
rogatio runtime host [path]
|
|
6856
6857
|
|
|
6857
6858
|
Native messaging runtime control for response-body and request-body rules. The
|
|
6858
6859
|
runtime no longer serves an HTTP mock server; mock delivery happens in the
|
|
6859
6860
|
consolidated native-messaging host (spec REQ-001..REQ-005).
|
|
6860
6861
|
|
|
6861
6862
|
Native runtime commands:
|
|
6862
|
-
|
|
6863
|
-
|
|
6864
|
-
|
|
6863
|
+
activate Activate the runtime (explicit, no auto-activation)
|
|
6864
|
+
deactivate Deactivate the runtime (idempotent)
|
|
6865
|
+
host [path] Run the consolidated native-messaging runtime host
|
|
6866
|
+
status Show the current runtime and trust state
|
|
6865
6867
|
|
|
6866
6868
|
Request-body trust commands:
|
|
6867
6869
|
install Install the native-messaging host manifest (requires --extension-id)
|
|
@@ -6870,17 +6872,17 @@ Request-body trust commands:
|
|
|
6870
6872
|
uninstall Uninstall the native-messaging host manifest (idempotent)
|
|
6871
6873
|
|
|
6872
6874
|
Native host command:
|
|
6873
|
-
|
|
6874
|
-
|
|
6875
|
-
|
|
6876
|
-
|
|
6875
|
+
host [path] Run the consolidated native-messaging runtime host. The browser
|
|
6876
|
+
launches this process via the native-messaging manifest; it reads
|
|
6877
|
+
pairing/authorization/mock envelopes from stdin and writes
|
|
6878
|
+
responses to stdout.
|
|
6877
6879
|
|
|
6878
6880
|
Options:
|
|
6879
6881
|
--root <dir> Root for confined file mocks (default: project directory)
|
|
6880
6882
|
--extension-id Extension ID for native messaging manifest (required for install)
|
|
6881
6883
|
--help, -h Show this help
|
|
6882
6884
|
|
|
6883
|
-
The native runtime activates unconditionally once
|
|
6885
|
+
The native runtime activates unconditionally once activated; the device-local CA /
|
|
6884
6886
|
PAC routing capability only affects request-body interception, not the host
|
|
6885
6887
|
control plane.
|
|
6886
6888
|
|
package/package.json
CHANGED