nolo-cli 0.180.0-alpha.1 → 0.181.0-alpha.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/{_executeModel-ACI2KGWO.js → _executeModel-EJUKYBFV.js} +17 -17
- package/{agentDeleteCommand-LVSLONDD.js → agentDeleteCommand-OWDZDREL.js} +22 -21
- package/{agentEmailCommands-BKH3Q6I6.js → agentEmailCommands-RJGVOJXD.js} +22 -21
- package/{agentListCommands-JPKRBHMP.js → agentListCommands-GRJAY5ZE.js} +6 -5
- package/{agentMachineCommands-HRORJN73.js → agentMachineCommands-FNYZSZQ4.js} +3 -3
- package/{agentRecordCommands-OSZF2EHL.js → agentRecordCommands-EBDTISRS.js} +21 -20
- package/{agentRunCommand-FCGNSB4D.js → agentRunCommand-GIBVOCOK.js} +22 -21
- package/{agentRuntimeLocal-SWG5ULIJ.js → agentRuntimeLocal-AG7RCTM3.js} +2 -2
- package/{agentSlice-FCDRLXVA.js → agentSlice-LD6SEBSP.js} +1 -1
- package/{appDeleteCommands-YH3BYQYK.js → appDeleteCommands-DXF3IOFE.js} +7 -6
- package/{appDeployCommands-F44TNQJG.js → appDeployCommands-JVKZ3ATD.js} +7 -6
- package/{appDeployStatusCommands-BFTGFVQY.js → appDeployStatusCommands-VLGEMFV6.js} +7 -6
- package/{appGetCommands-SFLFIXPW.js → appGetCommands-JQN7RPBD.js} +7 -6
- package/{appListCommands-RUO5SEAJ.js → appListCommands-MFPVNCVT.js} +7 -6
- package/{authCommand-UIF5UTYV.js → authCommand-AX23Q2Q5.js} +6 -5
- package/{authCommands-BKDT4ZYB.js → authCommands-PIUTADO5.js} +2 -2
- package/{chromeOpsCommands-IWKUA4C3.js → chromeOpsCommands-2KFQEE3H.js} +24 -46
- package/{chunk-6MXCQLLB.js → chunk-53HMDUG6.js} +14 -583
- package/{chunk-OBKPOFOB.js → chunk-5AIXW7RW.js} +10 -10
- package/{chunk-HS7JBDUJ.js → chunk-5LK5OYUB.js} +3 -3
- package/{chunk-QUCQVMYZ.js → chunk-7O6YJN4K.js} +6 -6
- package/{chunk-4KDYRX3O.js → chunk-CFW7JLTH.js} +2 -2
- package/{chunk-PD4KNHVU.js → chunk-CJYL3N3T.js} +2 -2
- package/{chunk-NJI5HZQA.js → chunk-DS47C2AI.js} +2 -2
- package/{chunk-DVSXZC7F.js → chunk-EP2L3JUM.js} +18 -18
- package/{chunk-SGATEZV5.js → chunk-F55WKIWE.js} +18 -18
- package/chunk-G5LNJZJH.js +584 -0
- package/{chunk-H63VHVFY.js → chunk-HZG23JG6.js} +3 -3
- package/{chunk-PT6335JZ.js → chunk-I4ZVPTAI.js} +1 -1
- package/chunk-LKZPX6YH.js +0 -0
- package/{chunk-TCCBECTT.js → chunk-MAS5KGBB.js} +5 -5
- package/{chunk-HTSXDJHA.js → chunk-OC4NVQ5S.js} +12 -12
- package/{chunk-GHKEUJ6I.js → chunk-OES4RYIG.js} +2 -2
- package/{chunk-TDX2L4W2.js → chunk-PS3GU7YU.js} +1857 -1138
- package/{chunk-CGKN34IJ.js → chunk-QZRAVGW3.js} +33 -33
- package/{chunk-GCAOOTIS.js → chunk-SCDJOWJT.js} +2 -2
- package/{chunk-YAN7XTXO.js → chunk-THZHXIKZ.js} +2 -2
- package/{chunk-WQAOAJ5Q.js → chunk-UCE66MIJ.js} +1 -1
- package/{chunk-DTA4JVXW.js → chunk-UXJ7R3EP.js} +2 -2
- package/{chunk-QOKJFYJK.js → chunk-WQ4M3IYD.js} +9 -9
- package/{commandRegistry-A2RXELBX.js → commandRegistry-XRHKJCWS.js} +80 -65
- package/{contentThunks-GZUPF67H.js → contentThunks-FBGQIS5J.js} +6 -6
- package/{cooldownCommands-NS63RGBO.js → cooldownCommands-QFV3ERZX.js} +14 -28
- package/{createAgentAutomationAction-ZOFCBZRE.js → createAgentAutomationAction-ASIS3C6Q.js} +6 -6
- package/{createDialogAction-G7QCYQT7.js → createDialogAction-XJGVTBWO.js} +7 -7
- package/{createPageAction-Z6JQZYS5.js → createPageAction-2IWTNKUE.js} +8 -8
- package/{dialogCommands-MITLWDBY.js → dialogCommands-VKBNO7EI.js} +2 -2
- package/{dialogSlice-PKFXK5WM.js → dialogSlice-BE76QRR4.js} +4 -4
- package/{docCreateCommands-G3S3LZMZ.js → docCreateCommands-HFDVOS2K.js} +11 -38
- package/{docDeleteCommands-MLRCMLVB.js → docDeleteCommands-DMKHPD5R.js} +17 -37
- package/{docReadCommands-6A6SBCOP.js → docReadCommands-VAUSL2N7.js} +12 -28
- package/{docStore-NAEY4CEK.js → docStore-FOTFZMVS.js} +1 -1
- package/{docUpdateCommands-UZQC2NDO.js → docUpdateCommands-6QQUX2IN.js} +19 -73
- package/{handleSendMessageAction-HUQLERJP.js → handleSendMessageAction-U6DQUBLF.js} +10 -10
- package/index.js +17 -7
- package/{localRuntimeAdapter-4DJDFM7A.js → localRuntimeAdapter-DM7ERZ6Z.js} +20 -19
- package/{machineCommands-A3WO3FMB.js → machineCommands-OJPPEMNZ.js} +326 -113
- package/{machineWsRunDispatch-CIJDSHTA.js → machineWsRunDispatch-I5WWJ2EY.js} +21 -20
- package/package.json +1 -1
- package/{readlineWorkspace-YCNAWRDL.js → readlineWorkspace-RMG27VY3.js} +31 -29
- package/{runAgentClientLoop-K7WRMT27.js → runAgentClientLoop-QJL24CN5.js} +15 -15
- package/{secretCommands-7S6REMJV.js → secretCommands-XEQLKDB4.js} +33 -47
- package/{spaceCommands-L537SH5I.js → spaceCommands-Z325DDJU.js} +2 -2
- package/{streamAgentChatTurn-HKUZ7OCA.js → streamAgentChatTurn-4ZA46AEJ.js} +19 -19
- package/{tools-NS37KPGT.js → tools-GWQ4POVC.js} +12 -12
- package/{updateCommands-BXGFH4VX.js → updateCommands-KDYX32JR.js} +3 -1
- package/{updateDialogTitleAction-UUZ5HDM2.js → updateDialogTitleAction-VTE36JGF.js} +6 -6
- package/windowsSelfUpdate-IYQK4IDS.js +14 -0
- package/{agentPullCommand-UXXV5KKW.js → agentPullCommand-7LHBOEYH.js} +1 -1
- package/{chunk-COXNBVP7.js → chunk-FLX5EYLQ.js} +4 -4
- package/{chunk-RV4DPEAM.js → chunk-XLQ646HU.js} +3 -3
- package/{workloadLifecycle-MZ2V5L43.js → workloadLifecycle-2F5YKFGW.js} +7 -7
|
@@ -5,27 +5,25 @@ import {
|
|
|
5
5
|
pickDefined,
|
|
6
6
|
printCliError,
|
|
7
7
|
resolveCliContext
|
|
8
|
-
} from "./chunk-
|
|
8
|
+
} from "./chunk-HZG23JG6.js";
|
|
9
9
|
import {
|
|
10
10
|
hasFlag,
|
|
11
11
|
hasHelpArg
|
|
12
12
|
} from "./chunk-4FZUUCXQ.js";
|
|
13
|
-
import
|
|
14
|
-
t
|
|
15
|
-
} from "./chunk-TDX2L4W2.js";
|
|
13
|
+
import "./chunk-LKZPX6YH.js";
|
|
16
14
|
import "./chunk-OXYSTN6B.js";
|
|
17
15
|
import "./chunk-CTEEJJVR.js";
|
|
18
16
|
import "./chunk-NBTY7YJF.js";
|
|
19
17
|
import "./chunk-VF4K2QE6.js";
|
|
20
18
|
import "./chunk-UAD2WT54.js";
|
|
21
|
-
import "./chunk-
|
|
19
|
+
import "./chunk-FLX5EYLQ.js";
|
|
22
20
|
import "./chunk-KMSMIOOL.js";
|
|
23
21
|
import "./chunk-ZNFJWEN4.js";
|
|
24
22
|
import "./chunk-YO776XHS.js";
|
|
25
23
|
import "./chunk-HNUWUO75.js";
|
|
24
|
+
import "./chunk-HIVDQPQR.js";
|
|
26
25
|
import "./chunk-CHOZJMJS.js";
|
|
27
26
|
import "./chunk-PWTNI4N7.js";
|
|
28
|
-
import "./chunk-HIVDQPQR.js";
|
|
29
27
|
import "./chunk-CR5WXQX7.js";
|
|
30
28
|
import "./chunk-2WZXXAQD.js";
|
|
31
29
|
import "./chunk-P2BGRAW7.js";
|
|
@@ -66,6 +64,9 @@ import {
|
|
|
66
64
|
import "./chunk-OLZBQWZU.js";
|
|
67
65
|
import "./chunk-LCBAMY2M.js";
|
|
68
66
|
import "./chunk-Y6ROFCZO.js";
|
|
67
|
+
import {
|
|
68
|
+
t
|
|
69
|
+
} from "./chunk-PS3GU7YU.js";
|
|
69
70
|
import "./chunk-HLAL63BZ.js";
|
|
70
71
|
import "./chunk-JOUFPRE4.js";
|
|
71
72
|
import "./chunk-WWC7I6TA.js";
|
|
@@ -4,27 +4,25 @@ import {
|
|
|
4
4
|
outputResult,
|
|
5
5
|
printCliError,
|
|
6
6
|
resolveCliContext
|
|
7
|
-
} from "./chunk-
|
|
7
|
+
} from "./chunk-HZG23JG6.js";
|
|
8
8
|
import {
|
|
9
9
|
hasFlag,
|
|
10
10
|
hasHelpArg
|
|
11
11
|
} from "./chunk-4FZUUCXQ.js";
|
|
12
|
-
import
|
|
13
|
-
t
|
|
14
|
-
} from "./chunk-TDX2L4W2.js";
|
|
12
|
+
import "./chunk-LKZPX6YH.js";
|
|
15
13
|
import "./chunk-OXYSTN6B.js";
|
|
16
14
|
import "./chunk-CTEEJJVR.js";
|
|
17
15
|
import "./chunk-NBTY7YJF.js";
|
|
18
16
|
import "./chunk-VF4K2QE6.js";
|
|
19
17
|
import "./chunk-UAD2WT54.js";
|
|
20
|
-
import "./chunk-
|
|
18
|
+
import "./chunk-FLX5EYLQ.js";
|
|
21
19
|
import "./chunk-KMSMIOOL.js";
|
|
22
20
|
import "./chunk-ZNFJWEN4.js";
|
|
23
21
|
import "./chunk-YO776XHS.js";
|
|
24
22
|
import "./chunk-HNUWUO75.js";
|
|
23
|
+
import "./chunk-HIVDQPQR.js";
|
|
25
24
|
import "./chunk-CHOZJMJS.js";
|
|
26
25
|
import "./chunk-PWTNI4N7.js";
|
|
27
|
-
import "./chunk-HIVDQPQR.js";
|
|
28
26
|
import "./chunk-CR5WXQX7.js";
|
|
29
27
|
import "./chunk-2WZXXAQD.js";
|
|
30
28
|
import "./chunk-P2BGRAW7.js";
|
|
@@ -65,6 +63,9 @@ import {
|
|
|
65
63
|
import "./chunk-OLZBQWZU.js";
|
|
66
64
|
import "./chunk-LCBAMY2M.js";
|
|
67
65
|
import "./chunk-Y6ROFCZO.js";
|
|
66
|
+
import {
|
|
67
|
+
t
|
|
68
|
+
} from "./chunk-PS3GU7YU.js";
|
|
68
69
|
import "./chunk-HLAL63BZ.js";
|
|
69
70
|
import "./chunk-JOUFPRE4.js";
|
|
70
71
|
import "./chunk-WWC7I6TA.js";
|
|
@@ -5,27 +5,25 @@ import {
|
|
|
5
5
|
pickDefined,
|
|
6
6
|
printCliError,
|
|
7
7
|
resolveCliContext
|
|
8
|
-
} from "./chunk-
|
|
8
|
+
} from "./chunk-HZG23JG6.js";
|
|
9
9
|
import {
|
|
10
10
|
hasFlag,
|
|
11
11
|
hasHelpArg
|
|
12
12
|
} from "./chunk-4FZUUCXQ.js";
|
|
13
|
-
import
|
|
14
|
-
t
|
|
15
|
-
} from "./chunk-TDX2L4W2.js";
|
|
13
|
+
import "./chunk-LKZPX6YH.js";
|
|
16
14
|
import "./chunk-OXYSTN6B.js";
|
|
17
15
|
import "./chunk-CTEEJJVR.js";
|
|
18
16
|
import "./chunk-NBTY7YJF.js";
|
|
19
17
|
import "./chunk-VF4K2QE6.js";
|
|
20
18
|
import "./chunk-UAD2WT54.js";
|
|
21
|
-
import "./chunk-
|
|
19
|
+
import "./chunk-FLX5EYLQ.js";
|
|
22
20
|
import "./chunk-KMSMIOOL.js";
|
|
23
21
|
import "./chunk-ZNFJWEN4.js";
|
|
24
22
|
import "./chunk-YO776XHS.js";
|
|
25
23
|
import "./chunk-HNUWUO75.js";
|
|
24
|
+
import "./chunk-HIVDQPQR.js";
|
|
26
25
|
import "./chunk-CHOZJMJS.js";
|
|
27
26
|
import "./chunk-PWTNI4N7.js";
|
|
28
|
-
import "./chunk-HIVDQPQR.js";
|
|
29
27
|
import "./chunk-CR5WXQX7.js";
|
|
30
28
|
import "./chunk-2WZXXAQD.js";
|
|
31
29
|
import "./chunk-P2BGRAW7.js";
|
|
@@ -66,6 +64,9 @@ import {
|
|
|
66
64
|
import "./chunk-OLZBQWZU.js";
|
|
67
65
|
import "./chunk-LCBAMY2M.js";
|
|
68
66
|
import "./chunk-Y6ROFCZO.js";
|
|
67
|
+
import {
|
|
68
|
+
t
|
|
69
|
+
} from "./chunk-PS3GU7YU.js";
|
|
69
70
|
import "./chunk-HLAL63BZ.js";
|
|
70
71
|
import "./chunk-JOUFPRE4.js";
|
|
71
72
|
import "./chunk-WWC7I6TA.js";
|
|
@@ -5,27 +5,25 @@ import {
|
|
|
5
5
|
pickDefined,
|
|
6
6
|
printCliError,
|
|
7
7
|
resolveCliContext
|
|
8
|
-
} from "./chunk-
|
|
8
|
+
} from "./chunk-HZG23JG6.js";
|
|
9
9
|
import {
|
|
10
10
|
hasFlag,
|
|
11
11
|
hasHelpArg
|
|
12
12
|
} from "./chunk-4FZUUCXQ.js";
|
|
13
|
-
import
|
|
14
|
-
t
|
|
15
|
-
} from "./chunk-TDX2L4W2.js";
|
|
13
|
+
import "./chunk-LKZPX6YH.js";
|
|
16
14
|
import "./chunk-OXYSTN6B.js";
|
|
17
15
|
import "./chunk-CTEEJJVR.js";
|
|
18
16
|
import "./chunk-NBTY7YJF.js";
|
|
19
17
|
import "./chunk-VF4K2QE6.js";
|
|
20
18
|
import "./chunk-UAD2WT54.js";
|
|
21
|
-
import "./chunk-
|
|
19
|
+
import "./chunk-FLX5EYLQ.js";
|
|
22
20
|
import "./chunk-KMSMIOOL.js";
|
|
23
21
|
import "./chunk-ZNFJWEN4.js";
|
|
24
22
|
import "./chunk-YO776XHS.js";
|
|
25
23
|
import "./chunk-HNUWUO75.js";
|
|
24
|
+
import "./chunk-HIVDQPQR.js";
|
|
26
25
|
import "./chunk-CHOZJMJS.js";
|
|
27
26
|
import "./chunk-PWTNI4N7.js";
|
|
28
|
-
import "./chunk-HIVDQPQR.js";
|
|
29
27
|
import "./chunk-CR5WXQX7.js";
|
|
30
28
|
import "./chunk-2WZXXAQD.js";
|
|
31
29
|
import "./chunk-P2BGRAW7.js";
|
|
@@ -66,6 +64,9 @@ import {
|
|
|
66
64
|
import "./chunk-OLZBQWZU.js";
|
|
67
65
|
import "./chunk-LCBAMY2M.js";
|
|
68
66
|
import "./chunk-Y6ROFCZO.js";
|
|
67
|
+
import {
|
|
68
|
+
t
|
|
69
|
+
} from "./chunk-PS3GU7YU.js";
|
|
69
70
|
import "./chunk-HLAL63BZ.js";
|
|
70
71
|
import "./chunk-JOUFPRE4.js";
|
|
71
72
|
import "./chunk-WWC7I6TA.js";
|
|
@@ -46,18 +46,17 @@ import {
|
|
|
46
46
|
validateXAIEndpoint,
|
|
47
47
|
xaiOAuthDiscovery
|
|
48
48
|
} from "./chunk-D2J22QSE.js";
|
|
49
|
-
import
|
|
50
|
-
t
|
|
51
|
-
} from "./chunk-TDX2L4W2.js";
|
|
49
|
+
import "./chunk-LKZPX6YH.js";
|
|
52
50
|
import {
|
|
53
51
|
defaultOpenBrowser
|
|
54
|
-
} from "./chunk-
|
|
52
|
+
} from "./chunk-XLQ646HU.js";
|
|
55
53
|
import "./chunk-TY3TIUJK.js";
|
|
56
54
|
import "./chunk-S73EPYNC.js";
|
|
57
55
|
import "./chunk-ZEZC7IIM.js";
|
|
58
56
|
import {
|
|
59
57
|
extractGoogleValidationLink
|
|
60
58
|
} from "./chunk-BMQ2MJUK.js";
|
|
59
|
+
import "./chunk-FDLDMJTM.js";
|
|
61
60
|
import "./chunk-OW765XBU.js";
|
|
62
61
|
import {
|
|
63
62
|
buildDevinAuthUrl,
|
|
@@ -79,7 +78,6 @@ import {
|
|
|
79
78
|
import "./chunk-5EMSBTQ6.js";
|
|
80
79
|
import "./chunk-I42VC5KR.js";
|
|
81
80
|
import "./chunk-U6VC4MU4.js";
|
|
82
|
-
import "./chunk-FDLDMJTM.js";
|
|
83
81
|
import "./chunk-GLKOYSRU.js";
|
|
84
82
|
import {
|
|
85
83
|
parseUserIdFromAuthToken
|
|
@@ -90,6 +88,9 @@ import {
|
|
|
90
88
|
getProfileOAuthSync,
|
|
91
89
|
saveProfileOAuthSync
|
|
92
90
|
} from "./chunk-R5GO3YZP.js";
|
|
91
|
+
import {
|
|
92
|
+
t
|
|
93
|
+
} from "./chunk-PS3GU7YU.js";
|
|
93
94
|
import "./chunk-JOUFPRE4.js";
|
|
94
95
|
import {
|
|
95
96
|
asOptionalFiniteNumber
|
|
@@ -7,15 +7,15 @@ import {
|
|
|
7
7
|
runLogoutCommand,
|
|
8
8
|
runWhoamiCommand,
|
|
9
9
|
saveTokenLogin
|
|
10
|
-
} from "./chunk-
|
|
10
|
+
} from "./chunk-XLQ646HU.js";
|
|
11
11
|
import "./chunk-TY3TIUJK.js";
|
|
12
12
|
import "./chunk-S73EPYNC.js";
|
|
13
13
|
import "./chunk-ZEZC7IIM.js";
|
|
14
|
+
import "./chunk-FDLDMJTM.js";
|
|
14
15
|
import "./chunk-OW765XBU.js";
|
|
15
16
|
import "./chunk-5EMSBTQ6.js";
|
|
16
17
|
import "./chunk-I42VC5KR.js";
|
|
17
18
|
import "./chunk-U6VC4MU4.js";
|
|
18
|
-
import "./chunk-FDLDMJTM.js";
|
|
19
19
|
import "./chunk-GLKOYSRU.js";
|
|
20
20
|
import "./chunk-WACI5I6V.js";
|
|
21
21
|
import "./chunk-OLZBQWZU.js";
|
|
@@ -8,6 +8,9 @@ import {
|
|
|
8
8
|
} from "./chunk-WACI5I6V.js";
|
|
9
9
|
import "./chunk-OLZBQWZU.js";
|
|
10
10
|
import "./chunk-LCBAMY2M.js";
|
|
11
|
+
import {
|
|
12
|
+
t
|
|
13
|
+
} from "./chunk-PS3GU7YU.js";
|
|
11
14
|
import "./chunk-KUG52IAP.js";
|
|
12
15
|
import {
|
|
13
16
|
toErrorMessage
|
|
@@ -50,7 +53,7 @@ function readIntOption(args, flag, usage) {
|
|
|
50
53
|
if (raw === void 0) return void 0;
|
|
51
54
|
const value = Number.parseInt(raw, 10);
|
|
52
55
|
if (!Number.isFinite(value)) {
|
|
53
|
-
throw new Error(
|
|
56
|
+
throw new Error(t("cliBrowserInvalidNumber", flag, usage));
|
|
54
57
|
}
|
|
55
58
|
return value;
|
|
56
59
|
}
|
|
@@ -59,24 +62,24 @@ function readNonNegativeIntOption(args, flag, usage) {
|
|
|
59
62
|
const raw = equalsForm !== void 0 ? equalsForm.slice(`${flag}=`.length) : readOption(args, flag);
|
|
60
63
|
if (raw === void 0) {
|
|
61
64
|
if (args.includes(flag)) {
|
|
62
|
-
throw new Error(
|
|
65
|
+
throw new Error(t("cliBrowserInvalidNumber", flag, usage));
|
|
63
66
|
}
|
|
64
67
|
return void 0;
|
|
65
68
|
}
|
|
66
69
|
const trimmed = raw.trim();
|
|
67
70
|
if (!/^\d+$/.test(trimmed)) {
|
|
68
|
-
throw new Error(
|
|
71
|
+
throw new Error(t("cliBrowserInvalidNumber", flag, usage));
|
|
69
72
|
}
|
|
70
73
|
const value = Number.parseInt(trimmed, 10);
|
|
71
74
|
if (!Number.isFinite(value) || value < 0) {
|
|
72
|
-
throw new Error(
|
|
75
|
+
throw new Error(t("cliBrowserInvalidNumber", flag, usage));
|
|
73
76
|
}
|
|
74
77
|
return value;
|
|
75
78
|
}
|
|
76
79
|
function requireTabId(args, usage) {
|
|
77
80
|
const tabId = readTrimmedOption(args, "--tab");
|
|
78
81
|
if (!tabId) {
|
|
79
|
-
throw new Error(
|
|
82
|
+
throw new Error(t("cliBrowserMissingTab", usage));
|
|
80
83
|
}
|
|
81
84
|
return tabId;
|
|
82
85
|
}
|
|
@@ -85,7 +88,7 @@ function requireTarget(args, usage) {
|
|
|
85
88
|
const selector = readTrimmedOption(args, "--selector");
|
|
86
89
|
if (!elementRef && !selector) {
|
|
87
90
|
throw new Error(
|
|
88
|
-
|
|
91
|
+
t("cliBrowserMissingTarget", usage)
|
|
89
92
|
);
|
|
90
93
|
}
|
|
91
94
|
return {
|
|
@@ -109,7 +112,7 @@ var CHROME_OPS_SUBCOMMANDS = {
|
|
|
109
112
|
payload: (args, usage) => {
|
|
110
113
|
const url = readTrimmedOption(args, "--url");
|
|
111
114
|
if (!url) {
|
|
112
|
-
throw new Error(
|
|
115
|
+
throw new Error(t("cliBrowserMissingUrl", usage));
|
|
113
116
|
}
|
|
114
117
|
return { url, active: args.includes("--active") };
|
|
115
118
|
}
|
|
@@ -150,7 +153,7 @@ var CHROME_OPS_SUBCOMMANDS = {
|
|
|
150
153
|
payload: (args, usage) => {
|
|
151
154
|
const text = readOption(args, "--text");
|
|
152
155
|
if (text === void 0 || text.startsWith("--")) {
|
|
153
|
-
throw new Error(
|
|
156
|
+
throw new Error(t("cliBrowserMissingText", usage));
|
|
154
157
|
}
|
|
155
158
|
return withApprovalId(args, {
|
|
156
159
|
tabId: requireTabId(args, usage),
|
|
@@ -187,7 +190,7 @@ var CHROME_OPS_SUBCOMMANDS = {
|
|
|
187
190
|
payload: (args, usage) => {
|
|
188
191
|
const files = readAllOptions(args, "--file");
|
|
189
192
|
if (files.length === 0) {
|
|
190
|
-
throw new Error(
|
|
193
|
+
throw new Error(t("cliBrowserMissingFile", usage));
|
|
191
194
|
}
|
|
192
195
|
const target = requireTarget(args, usage);
|
|
193
196
|
const tabId = requireTabId(args, usage);
|
|
@@ -205,7 +208,7 @@ var CHROME_OPS_SUBCOMMANDS = {
|
|
|
205
208
|
payload: (args, usage) => {
|
|
206
209
|
const key = readTrimmedOption(args, "--key");
|
|
207
210
|
if (!key) {
|
|
208
|
-
throw new Error(
|
|
211
|
+
throw new Error(t("cliBrowserMissingKey", usage));
|
|
209
212
|
}
|
|
210
213
|
return withApprovalId(args, { tabId: requireTabId(args, usage), key });
|
|
211
214
|
}
|
|
@@ -217,15 +220,15 @@ var CHROME_OPS_SUBCOMMANDS = {
|
|
|
217
220
|
const tabId = requireTabId(args, usage);
|
|
218
221
|
const action = readTrimmedOption(args, "--action").toLowerCase();
|
|
219
222
|
if (!action || !["click", "type", "press"].includes(action)) {
|
|
220
|
-
throw new Error(
|
|
223
|
+
throw new Error(t("cliBrowserAction", usage));
|
|
221
224
|
}
|
|
222
225
|
if (readOption(args, "--ref") !== void 0) {
|
|
223
|
-
throw new Error(
|
|
226
|
+
throw new Error(t("cliBrowserRefUnsupported", usage));
|
|
224
227
|
}
|
|
225
228
|
const active = args.includes("--active");
|
|
226
229
|
const selector = readTrimmedOption(args, "--selector");
|
|
227
230
|
if (!active && !selector && action !== "press") {
|
|
228
|
-
throw new Error(
|
|
231
|
+
throw new Error(t("cliBrowserSelector", usage));
|
|
229
232
|
}
|
|
230
233
|
const payload = {
|
|
231
234
|
tabId,
|
|
@@ -236,7 +239,7 @@ var CHROME_OPS_SUBCOMMANDS = {
|
|
|
236
239
|
if (action === "type") {
|
|
237
240
|
const text = readOption(args, "--text");
|
|
238
241
|
if (text === void 0 || text.startsWith("--")) {
|
|
239
|
-
throw new Error(
|
|
242
|
+
throw new Error(t("cliBrowserTypeText", usage));
|
|
240
243
|
}
|
|
241
244
|
payload.text = text;
|
|
242
245
|
if (args.includes("--append")) {
|
|
@@ -245,7 +248,7 @@ var CHROME_OPS_SUBCOMMANDS = {
|
|
|
245
248
|
} else if (action === "press") {
|
|
246
249
|
const key = readTrimmedOption(args, "--key");
|
|
247
250
|
if (!key) {
|
|
248
|
-
throw new Error(
|
|
251
|
+
throw new Error(t("cliBrowserPressKey", usage));
|
|
249
252
|
}
|
|
250
253
|
payload.key = key;
|
|
251
254
|
}
|
|
@@ -302,38 +305,14 @@ var CHROME_OPS_SUBCOMMANDS = {
|
|
|
302
305
|
};
|
|
303
306
|
function renderChromeOpsHelp() {
|
|
304
307
|
const lines = [
|
|
305
|
-
"
|
|
306
|
-
"(the desktop bridge; the same RPC the browser_* agent tools use \u2014 legacy `chrome_*` names still work).",
|
|
307
|
-
"",
|
|
308
|
-
"Usage:",
|
|
309
|
-
" nolo browser <subcommand> [flags]",
|
|
310
|
-
" nolo chrome <subcommand> [flags] # compatibility alias",
|
|
311
|
-
"",
|
|
312
|
-
"Subcommands:",
|
|
308
|
+
t("cliBrowserHelpIntro"),
|
|
313
309
|
...Object.values(CHROME_OPS_SUBCOMMANDS).map(
|
|
314
310
|
(spec) => ` ${spec.usage.replace(/^nolo browser /, "")}`
|
|
315
311
|
),
|
|
316
|
-
""
|
|
317
|
-
"Notes:",
|
|
318
|
-
" --ref takes an elementRef copied from `nolo browser read-page` (revision-scoped,",
|
|
319
|
-
" preferred over --selector); --selector takes a CSS selector.",
|
|
320
|
-
" Actions the connector classifies as irreversible (pay / send / delete / publish / permission)",
|
|
321
|
-
" open a confirmation request in the browser and return USER_APPROVAL_PENDING with an approvalId:",
|
|
322
|
-
' the user clicks "Allow once" there, then rerun the same command with --approval-id <id>.',
|
|
323
|
-
" That id is not an authorization \u2014 only the lookup key for the decision the user already made.",
|
|
324
|
-
" prepare-action prepares an immutable action challenge binding for host consent verification;",
|
|
325
|
-
" it is strictly read-only, never executes mutations, and does not grant approval.",
|
|
326
|
-
" read-console / read-network / upload work on Chrome only (Firefox lacks chrome.debugger).",
|
|
327
|
-
" --browser chrome|firefox selects which connector endpoint serves the call (default",
|
|
328
|
-
" auto-detects single online browser: chrome = 127.0.0.1:38947, firefox = 127.0.0.1:38948);",
|
|
329
|
-
" the wrong browser is refused.",
|
|
330
|
-
" Every subcommand prints the connector's raw JSON result; failures exit 1.",
|
|
331
|
-
" Endpoint: NOLO_CHROME_CONNECTOR_RPC_URL or per-browser NOLO_CHROME_CONNECTOR_PORT /",
|
|
332
|
-
" NOLO_FIREFOX_CONNECTOR_PORT (default http://127.0.0.1:38947/rpc)."
|
|
312
|
+
t("cliBrowserHelpNotes")
|
|
333
313
|
];
|
|
334
314
|
return lines.join("\n");
|
|
335
315
|
}
|
|
336
|
-
var CHROME_OPS_HELP_TEXT = renderChromeOpsHelp();
|
|
337
316
|
async function defaultProbeBrowser(browser) {
|
|
338
317
|
try {
|
|
339
318
|
const client = createChromeConnectorClient({
|
|
@@ -367,19 +346,19 @@ async function runChromeOpsCommand(subcommand, args, deps = {}) {
|
|
|
367
346
|
};
|
|
368
347
|
const spec = CHROME_OPS_SUBCOMMANDS[subcommand];
|
|
369
348
|
if (!spec) {
|
|
370
|
-
io.stderr(
|
|
349
|
+
io.stderr(`${t("cliBrowserUnknown", subcommand)}
|
|
371
350
|
|
|
372
|
-
${
|
|
351
|
+
${renderChromeOpsHelp()}`);
|
|
373
352
|
return 1;
|
|
374
353
|
}
|
|
375
354
|
if (wantsHelp(args)) {
|
|
376
|
-
io.stdout(
|
|
355
|
+
io.stdout(renderChromeOpsHelp());
|
|
377
356
|
return 0;
|
|
378
357
|
}
|
|
379
358
|
const browserFlag = readBrowserFlag(args);
|
|
380
359
|
if (browserFlag === null) {
|
|
381
360
|
io.stderr(
|
|
382
|
-
|
|
361
|
+
t("cliBrowserBrowser", spec.usage)
|
|
383
362
|
);
|
|
384
363
|
return 1;
|
|
385
364
|
}
|
|
@@ -493,7 +472,6 @@ ${CHROME_OPS_HELP_TEXT}`);
|
|
|
493
472
|
return 0;
|
|
494
473
|
}
|
|
495
474
|
export {
|
|
496
|
-
CHROME_OPS_HELP_TEXT,
|
|
497
475
|
CHROME_OPS_SUBCOMMANDS,
|
|
498
476
|
renderChromeOpsHelp,
|
|
499
477
|
runChromeOpsCommand
|