@modootoday/pmcp 0.24.0 → 0.25.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/.agents/plugins/marketplace.json +1 -1
- package/.claude-plugin/marketplace.json +1 -1
- package/.claude-plugin/plugin.json +1 -1
- package/.mcp.json +1 -1
- package/dist/{affected-D6FRJPPI.js → affected-IPFJM2KD.js} +484 -140
- package/dist/{apply-6JVJ7FDZ.js → apply-6XLLYLJT.js} +15 -14
- package/dist/{broadcast-VKZY7WSD.js → broadcast-34CEG2NQ.js} +5 -2
- package/dist/{chunk-B3OZ4GGO.js → chunk-23PE3HZB.js} +16 -1
- package/dist/{chunk-42SO7KYX.js → chunk-2GD7PQ7J.js} +2 -2
- package/dist/{chunk-7A6QIROT.js → chunk-2TXVOHRS.js} +3 -3
- package/dist/{chunk-QR4GXET7.js → chunk-3P6Y2BAO.js} +3 -3
- package/dist/{chunk-5QBOGEVE.js → chunk-5MUD7FHP.js} +2 -2
- package/dist/{chunk-2GZKA33O.js → chunk-A4P3IIPE.js} +2 -2
- package/dist/{chunk-UFWW4H6V.js → chunk-BG6TONJO.js} +2 -2
- package/dist/{chunk-HES44LTA.js → chunk-C3KRMTIZ.js} +28 -4
- package/dist/{chunk-QY2P54Z2.js → chunk-DITIXBFB.js} +61 -8
- package/dist/{chunk-6UGHVU5B.js → chunk-DWHM5BAY.js} +2 -2
- package/dist/{chunk-TIH7JFPJ.js → chunk-EC5QLEZD.js} +2 -2
- package/dist/{chunk-RZYZILU4.js → chunk-EWYLWBKS.js} +2 -2
- package/dist/{chunk-LI3BII4F.js → chunk-ISWR2XIU.js} +2 -2
- package/dist/{chunk-WNP2BXR7.js → chunk-LZVHFPN6.js} +5 -5
- package/dist/{chunk-K6ATERWS.js → chunk-MBHI2TKQ.js} +4 -4
- package/dist/{chunk-43MXRTKH.js → chunk-NAHAESFV.js} +9 -4
- package/dist/chunk-NQCAKDRY.js +156 -0
- package/dist/chunk-OIKT4SYO.js +42 -0
- package/dist/{chunk-D2MHB5EF.js → chunk-PECS47OL.js} +3 -3
- package/dist/{chunk-62BC3K4Z.js → chunk-PGZZI42O.js} +2 -2
- package/dist/{chunk-S6G7YWNE.js → chunk-QYHM6554.js} +2 -2
- package/dist/{chunk-2W2F5BWF.js → chunk-RF6RDJYH.js} +16 -16
- package/dist/{chunk-SUDG7B6S.js → chunk-SDFJJJB5.js} +2 -2
- package/dist/chunk-SMBU3QLE.js +7 -0
- package/dist/{chunk-644GNYMB.js → chunk-SRSKCFFS.js} +3 -3
- package/dist/{chunk-LB2WXBPA.js → chunk-SSQ6EWNA.js} +5 -5
- package/dist/{chunk-56VBB3H7.js → chunk-TJW4DP26.js} +2 -2
- package/dist/{chunk-25M2YWBH.js → chunk-TOR6SKRB.js} +146 -63
- package/dist/{chunk-ISGHJHVH.js → chunk-UQHJUTDW.js} +2 -2
- package/dist/{chunk-M6X6HVQK.js → chunk-VQBXWMLT.js} +2 -2
- package/dist/{chunk-UYBWUOLR.js → chunk-VYQJPT27.js} +4 -4
- package/dist/{cli-GFDT4YXM.js → cli-5G2OYTIL.js} +9 -9
- package/dist/{cli-WWNTQJPV.js → cli-QDQYUHAP.js} +9 -9
- package/dist/cli.js +38 -5
- package/dist/{completion-I63UIDZ7.js → completion-3GVNPLZY.js} +4 -4
- package/dist/{diagnostics-RUJZBPNZ.js → diagnostics-2W7QDQNG.js} +6 -6
- package/dist/{doctor-CLUFTEFO.js → doctor-3TDO5LJ5.js} +17 -16
- package/dist/{entry-QSJCFI5Z.js → entry-E62DZQJF.js} +10 -10
- package/dist/{exec-mcp-AFPUJTN7.js → exec-mcp-4N7FLY52.js} +13 -12
- package/dist/{harness-PPM32AI5.js → harness-E2AUZDLV.js} +3 -3
- package/dist/harness-launch-gate.js +4 -4
- package/dist/harness-worker.js +6 -6
- package/dist/{heavy-TEHP5PHT.js → heavy-HZQVFI6P.js} +182 -52
- package/dist/hook-body.js +116 -45
- package/dist/{hooks-L4PXVEGR.js → hooks-VAEAK2FY.js} +4 -4
- package/dist/{host-MU2GRH57.js → host-4GJDGTLW.js} +7 -7
- package/dist/{host-LBTL47X7.js → host-I2EMQ7UE.js} +18 -65
- package/dist/{host-run-IRSAQA5Z.js → host-run-DDMKD3BU.js} +5 -5
- package/dist/http.js +1 -1
- package/dist/{import-mcp-QVPW6A2Q.js → import-mcp-TNSAMJXI.js} +12 -11
- package/dist/index.d.ts +1 -1
- package/dist/index.js +16 -15
- package/dist/{init-46STH6FP.js → init-UA7MDNTZ.js} +2 -2
- package/dist/{invoke-I6C6UT6Q.js → invoke-HW7NBPGP.js} +8 -8
- package/dist/{list-HXG6EB7V.js → list-A7VQJXE5.js} +14 -13
- package/dist/{logout-SSUXJ6SE.js → logout-HNPLUKJY.js} +13 -12
- package/dist/{mailbox-5FVFMQ2J.js → mailbox-MR6TPD3P.js} +20 -6
- package/dist/{mainline-4XP6ZORU.js → mainline-MSLW3UFD.js} +14 -8
- package/dist/{mcp-L6X45IOS.js → mcp-6C23GX2E.js} +2 -2
- package/dist/{modes-SEINLLMK.js → modes-7OY7R73T.js} +3 -3
- package/dist/{pause-CMZOIHTJ.js → pause-H6ZYZF7C.js} +5 -2
- package/dist/{project-4JPKU2D7.js → project-BX6NCGKB.js} +4 -4
- package/dist/{report-UB7MXAUB.js → report-43SFNNCF.js} +2 -2
- package/dist/{resume-PAKIT4TT.js → resume-2BWGSTCN.js} +5 -2
- package/dist/{run-PMASXIGY.js → run-2UVAWBAF.js} +12 -11
- package/dist/{run-OW7436TY.js → run-7TRWZFEZ.js} +4 -4
- package/dist/{serve-P3HJN6AF.js → serve-4XZ5SKJJ.js} +3 -3
- package/dist/{setup-6AQUOWOH.js → setup-GRWLDBVB.js} +4 -4
- package/dist/{start-login-P7YDRTA3.js → start-login-AR7ITWNV.js} +13 -12
- package/dist/{status-4PYPTYUB.js → status-2GDYLIR3.js} +6 -3
- package/dist/{status-DAXQKT35.js → status-VQCMJFVE.js} +31 -28
- package/dist/{status-DLGZDYEP.js → status-ZY6LDQSF.js} +13 -12
- package/dist/stdio.js +2 -2
- package/dist/{sweep-VURZU6DI.js → sweep-76BUOGEI.js} +5 -2
- package/dist/{test-H243OTSK.js → test-VWGNFSH5.js} +15 -13
- package/dist/{tui-P6XTSTQO.js → tui-TUMOQBE7.js} +4 -4
- package/dist/{unbroadcast-7AMLURCG.js → unbroadcast-HJHYUHZL.js} +5 -2
- package/dist/{worker-5YJLIGTU.js → worker-NEEPJRVV.js} +8 -8
- package/dist/{worktree-create-FTSLMZWS.js → worktree-create-ZQRN5JBD.js} +2 -2
- package/dist/{worktree-list-WH6OX6U7.js → worktree-list-WZC75NLF.js} +11 -12
- package/dist/{worktree-sync-DGNHSQ64.js → worktree-sync-MUVKK2CV.js} +5 -5
- package/docs/commands.md +9 -7
- package/docs/git-workflow.md +7 -1
- package/docs/glossary.md +1 -1
- package/docs/hooks.md +20 -16
- package/docs/project-configuration.md +76 -37
- package/docs/sessions.md +9 -2
- package/docs/upgrading.md +58 -0
- package/gemini-extension.json +2 -2
- package/mcp.json +1 -1
- package/package.json +5 -5
- package/plugin.json +1 -1
- package/plugins/pmcp/.claude-plugin/plugin.json +1 -1
- package/plugins/pmcp/.mcp.json +1 -1
- package/plugins/pmcp/gemini-extension.json +2 -2
- package/plugins/pmcp/mcp.json +1 -1
- package/plugins/pmcp/plugin.json +1 -1
- package/dist/chunk-LTMHE5VL.js +0 -7
|
@@ -3,7 +3,7 @@ import {
|
|
|
3
3
|
} from "./chunk-2MX5C7B2.js";
|
|
4
4
|
import {
|
|
5
5
|
specFrom
|
|
6
|
-
} from "./chunk-
|
|
6
|
+
} from "./chunk-BG6TONJO.js";
|
|
7
7
|
import {
|
|
8
8
|
printSmoke,
|
|
9
9
|
runSmoke
|
|
@@ -15,28 +15,29 @@ import {
|
|
|
15
15
|
describeHookProblem,
|
|
16
16
|
project,
|
|
17
17
|
unmanagedHookProblems
|
|
18
|
-
} from "./chunk-
|
|
18
|
+
} from "./chunk-MBHI2TKQ.js";
|
|
19
19
|
import "./chunk-ANJMLKBR.js";
|
|
20
|
-
import "./chunk-
|
|
20
|
+
import "./chunk-SRSKCFFS.js";
|
|
21
21
|
import {
|
|
22
22
|
checkBudget,
|
|
23
23
|
renderFrontmatter,
|
|
24
24
|
splitFrontmatter
|
|
25
|
-
} from "./chunk-
|
|
26
|
-
import "./chunk-
|
|
25
|
+
} from "./chunk-TOR6SKRB.js";
|
|
26
|
+
import "./chunk-VYQJPT27.js";
|
|
27
27
|
import "./chunk-UKR64U7J.js";
|
|
28
|
-
import "./chunk-
|
|
28
|
+
import "./chunk-2GD7PQ7J.js";
|
|
29
29
|
import "./chunk-EATCUWGG.js";
|
|
30
30
|
import "./chunk-OFJIMBTL.js";
|
|
31
|
+
import "./chunk-NQCAKDRY.js";
|
|
31
32
|
import "./chunk-LFFIQBNY.js";
|
|
32
33
|
import "./chunk-HQOB7OQS.js";
|
|
33
34
|
import "./chunk-73AKO4UL.js";
|
|
34
|
-
import "./chunk-
|
|
35
|
-
import "./chunk-
|
|
36
|
-
import "./chunk-
|
|
35
|
+
import "./chunk-VQBXWMLT.js";
|
|
36
|
+
import "./chunk-EWYLWBKS.js";
|
|
37
|
+
import "./chunk-SDFJJJB5.js";
|
|
37
38
|
import "./chunk-3V37OZQH.js";
|
|
38
39
|
import "./chunk-Z6WRFOFT.js";
|
|
39
|
-
import "./chunk-
|
|
40
|
+
import "./chunk-23PE3HZB.js";
|
|
40
41
|
import "./chunk-Q5H3L6Y4.js";
|
|
41
42
|
import {
|
|
42
43
|
RUNTIMES,
|
|
@@ -54,8 +55,8 @@ import {
|
|
|
54
55
|
import "./chunk-YSAWTGNA.js";
|
|
55
56
|
import {
|
|
56
57
|
recordProjector
|
|
57
|
-
} from "./chunk-
|
|
58
|
-
import "./chunk-
|
|
58
|
+
} from "./chunk-2TXVOHRS.js";
|
|
59
|
+
import "./chunk-DITIXBFB.js";
|
|
59
60
|
import "./chunk-N7ANFMA5.js";
|
|
60
61
|
import {
|
|
61
62
|
ProjectError
|
|
@@ -65,7 +66,7 @@ import "./chunk-FQLCD4HU.js";
|
|
|
65
66
|
import "./chunk-GUHOEIHP.js";
|
|
66
67
|
import "./chunk-IJBSOWHK.js";
|
|
67
68
|
import "./chunk-XWLMZKH2.js";
|
|
68
|
-
import "./chunk-
|
|
69
|
+
import "./chunk-SMBU3QLE.js";
|
|
69
70
|
import "./chunk-GJXOFDJT.js";
|
|
70
71
|
import "./chunk-PMJG2CXF.js";
|
|
71
72
|
import "./chunk-J6KL3COD.js";
|
|
@@ -280,4 +281,4 @@ export {
|
|
|
280
281
|
projectOrCheck,
|
|
281
282
|
removeAndProject
|
|
282
283
|
};
|
|
283
|
-
//# sourceMappingURL=apply-
|
|
284
|
+
//# sourceMappingURL=apply-6XLLYLJT.js.map
|
|
@@ -1,6 +1,9 @@
|
|
|
1
1
|
import {
|
|
2
2
|
change
|
|
3
|
-
} from "./chunk-
|
|
3
|
+
} from "./chunk-C3KRMTIZ.js";
|
|
4
|
+
import "./chunk-65BW7Y6O.js";
|
|
5
|
+
import "./chunk-OIKT4SYO.js";
|
|
6
|
+
import "./chunk-NQCAKDRY.js";
|
|
4
7
|
import "./chunk-3V37OZQH.js";
|
|
5
8
|
import "./chunk-Z6WRFOFT.js";
|
|
6
9
|
import "./chunk-Y6NFETNG.js";
|
|
@@ -15,4 +18,4 @@ var run = (context) => change(context, "broadcast");
|
|
|
15
18
|
export {
|
|
16
19
|
run
|
|
17
20
|
};
|
|
18
|
-
//# sourceMappingURL=broadcast-
|
|
21
|
+
//# sourceMappingURL=broadcast-34CEG2NQ.js.map
|
|
@@ -35,6 +35,20 @@ function gitWithInput(cwd, args, input) {
|
|
|
35
35
|
const stderr = run.stderr || run.error?.message || "";
|
|
36
36
|
return { status: run.status ?? 1, stdout: run.stdout ?? "", stderr };
|
|
37
37
|
}
|
|
38
|
+
function gitBytes(cwd, args, input) {
|
|
39
|
+
const run = spawnSync("git", args, {
|
|
40
|
+
cwd,
|
|
41
|
+
env: cleanEnv(),
|
|
42
|
+
maxBuffer: 1024 * 1024 * 1024,
|
|
43
|
+
...input === void 0 ? {} : { input }
|
|
44
|
+
});
|
|
45
|
+
const stderr = run.stderr?.toString() || run.error?.message || "";
|
|
46
|
+
return {
|
|
47
|
+
status: run.status ?? 1,
|
|
48
|
+
stdout: run.stdout ?? Buffer.alloc(0),
|
|
49
|
+
stderr
|
|
50
|
+
};
|
|
51
|
+
}
|
|
38
52
|
function gitText(cwd, args) {
|
|
39
53
|
const run = git(cwd, args);
|
|
40
54
|
if (run.status !== 0) return "";
|
|
@@ -84,9 +98,10 @@ function runCommand(argv, cwd, extra) {
|
|
|
84
98
|
export {
|
|
85
99
|
git,
|
|
86
100
|
gitWithInput,
|
|
101
|
+
gitBytes,
|
|
87
102
|
gitText,
|
|
88
103
|
gitOk,
|
|
89
104
|
runCommandLogged,
|
|
90
105
|
runCommand
|
|
91
106
|
};
|
|
92
|
-
//# sourceMappingURL=chunk-
|
|
107
|
+
//# sourceMappingURL=chunk-23PE3HZB.js.map
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import {
|
|
2
2
|
git,
|
|
3
3
|
gitText
|
|
4
|
-
} from "./chunk-
|
|
4
|
+
} from "./chunk-23PE3HZB.js";
|
|
5
5
|
|
|
6
6
|
// src/git/superseded.ts
|
|
7
7
|
import { existsSync } from "fs";
|
|
@@ -129,4 +129,4 @@ export {
|
|
|
129
129
|
isAncestor,
|
|
130
130
|
distance
|
|
131
131
|
};
|
|
132
|
-
//# sourceMappingURL=chunk-
|
|
132
|
+
//# sourceMappingURL=chunk-2GD7PQ7J.js.map
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import {
|
|
2
2
|
readLeaseSettings
|
|
3
|
-
} from "./chunk-
|
|
3
|
+
} from "./chunk-DITIXBFB.js";
|
|
4
4
|
import {
|
|
5
5
|
ProjectError
|
|
6
6
|
} from "./chunk-TYY5TYHF.js";
|
|
@@ -12,7 +12,7 @@ import {
|
|
|
12
12
|
} from "./chunk-XWLMZKH2.js";
|
|
13
13
|
import {
|
|
14
14
|
VERSION
|
|
15
|
-
} from "./chunk-
|
|
15
|
+
} from "./chunk-SMBU3QLE.js";
|
|
16
16
|
import {
|
|
17
17
|
ConfigError
|
|
18
18
|
} from "./chunk-GJXOFDJT.js";
|
|
@@ -610,4 +610,4 @@ export {
|
|
|
610
610
|
hostEnvDoctor,
|
|
611
611
|
hostDoctor
|
|
612
612
|
};
|
|
613
|
-
//# sourceMappingURL=chunk-
|
|
613
|
+
//# sourceMappingURL=chunk-2TXVOHRS.js.map
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import {
|
|
2
2
|
assertNativeHost
|
|
3
|
-
} from "./chunk-
|
|
3
|
+
} from "./chunk-ISWR2XIU.js";
|
|
4
4
|
import {
|
|
5
5
|
locateExecutable
|
|
6
6
|
} from "./chunk-R2GPCZUX.js";
|
|
@@ -33,7 +33,7 @@ import {
|
|
|
33
33
|
resourceClaim,
|
|
34
34
|
resourceRunning,
|
|
35
35
|
runtimeUnit
|
|
36
|
-
} from "./chunk-
|
|
36
|
+
} from "./chunk-DWHM5BAY.js";
|
|
37
37
|
import {
|
|
38
38
|
command
|
|
39
39
|
} from "./chunk-34DECPVC.js";
|
|
@@ -1981,4 +1981,4 @@ export {
|
|
|
1981
1981
|
isReadOnly,
|
|
1982
1982
|
runOperation
|
|
1983
1983
|
};
|
|
1984
|
-
//# sourceMappingURL=chunk-
|
|
1984
|
+
//# sourceMappingURL=chunk-3P6Y2BAO.js.map
|
|
@@ -1190,7 +1190,7 @@ function registerReadTool(server, tools) {
|
|
|
1190
1190
|
|
|
1191
1191
|
// src/mcp.ts
|
|
1192
1192
|
var SERVER_NAME = "pmcp";
|
|
1193
|
-
var SERVER_VERSION = "0.
|
|
1193
|
+
var SERVER_VERSION = "0.25.0";
|
|
1194
1194
|
var MAX_TOOL_INPUT_ELEMENTS = 1e4;
|
|
1195
1195
|
function registerSkillTools(server, tools) {
|
|
1196
1196
|
registerCatalogTool(server, tools);
|
|
@@ -1247,4 +1247,4 @@ export {
|
|
|
1247
1247
|
registerSkillTools,
|
|
1248
1248
|
createSkillServer
|
|
1249
1249
|
};
|
|
1250
|
-
//# sourceMappingURL=chunk-
|
|
1250
|
+
//# sourceMappingURL=chunk-5MUD7FHP.js.map
|
|
@@ -122,7 +122,7 @@ var sessionsSpec = {
|
|
|
122
122
|
nearestConfigOption,
|
|
123
123
|
{
|
|
124
124
|
name: "by",
|
|
125
|
-
describe: "Who pauses, broadcasts or sends; that session is exempt. Default operator.",
|
|
125
|
+
describe: "Who pauses, broadcasts or sends; that session is exempt. Default: the agent session this runs in; operator only from the operator's terminal.",
|
|
126
126
|
placeholder: "<name>"
|
|
127
127
|
},
|
|
128
128
|
{
|
|
@@ -170,4 +170,4 @@ export {
|
|
|
170
170
|
JSON_VERBS,
|
|
171
171
|
sessionsSpec
|
|
172
172
|
};
|
|
173
|
-
//# sourceMappingURL=chunk-
|
|
173
|
+
//# sourceMappingURL=chunk-A4P3IIPE.js.map
|
|
@@ -3,7 +3,7 @@ import {
|
|
|
3
3
|
} from "./chunk-7CHUMF3E.js";
|
|
4
4
|
import {
|
|
5
5
|
readSpec
|
|
6
|
-
} from "./chunk-
|
|
6
|
+
} from "./chunk-TOR6SKRB.js";
|
|
7
7
|
import {
|
|
8
8
|
ArgumentError,
|
|
9
9
|
noConfig
|
|
@@ -27,4 +27,4 @@ function specFrom(context) {
|
|
|
27
27
|
export {
|
|
28
28
|
specFrom
|
|
29
29
|
};
|
|
30
|
-
//# sourceMappingURL=chunk-
|
|
30
|
+
//# sourceMappingURL=chunk-BG6TONJO.js.map
|
|
@@ -1,7 +1,17 @@
|
|
|
1
|
+
import {
|
|
2
|
+
inferSession
|
|
3
|
+
} from "./chunk-65BW7Y6O.js";
|
|
4
|
+
import {
|
|
5
|
+
isOperator,
|
|
6
|
+
requireOperatorFor
|
|
7
|
+
} from "./chunk-OIKT4SYO.js";
|
|
1
8
|
import {
|
|
2
9
|
openStore,
|
|
3
10
|
readStoreSettings
|
|
4
11
|
} from "./chunk-3V37OZQH.js";
|
|
12
|
+
import {
|
|
13
|
+
ancestors
|
|
14
|
+
} from "./chunk-Z6WRFOFT.js";
|
|
5
15
|
import {
|
|
6
16
|
ArgumentError,
|
|
7
17
|
noConfig,
|
|
@@ -13,6 +23,7 @@ import {
|
|
|
13
23
|
} from "./chunk-GJXOFDJT.js";
|
|
14
24
|
|
|
15
25
|
// src/sessions/cli/verbs.ts
|
|
26
|
+
var OPERATOR = "operator";
|
|
16
27
|
function storeFrom(context) {
|
|
17
28
|
const path = one(context.args, "config") ?? findConfig(context.cwd);
|
|
18
29
|
if (!path) throw noConfig();
|
|
@@ -37,12 +48,25 @@ function text(context, verb) {
|
|
|
37
48
|
);
|
|
38
49
|
return words;
|
|
39
50
|
}
|
|
51
|
+
function actor(context, store) {
|
|
52
|
+
const given = one(context.args, "by");
|
|
53
|
+
if (given !== void 0 && given !== OPERATOR) return given;
|
|
54
|
+
if (given === void 0) {
|
|
55
|
+
const found = inferSession(context.env, store.registry.list(), ancestors());
|
|
56
|
+
if (found.session) return found.session;
|
|
57
|
+
}
|
|
58
|
+
if (isOperator(context)) return OPERATOR;
|
|
59
|
+
throw new ArgumentError(
|
|
60
|
+
given === OPERATOR ? "--by operator is for the operator's own terminal; name yourself with --by <name>" : "say who acts with --by <name>: no agent session or operator terminal was found"
|
|
61
|
+
);
|
|
62
|
+
}
|
|
40
63
|
function change(context, verb) {
|
|
41
64
|
const { store } = storeFrom(context);
|
|
42
|
-
|
|
65
|
+
if (verb === "pause" || verb === "resume")
|
|
66
|
+
requireOperatorFor(context, `pmcp sessions ${verb}`);
|
|
43
67
|
if (verb === "pause") {
|
|
44
68
|
const reason = text(context, verb);
|
|
45
|
-
store.pause.write({ by, reason });
|
|
69
|
+
store.pause.write({ by: one(context.args, "by") ?? OPERATOR, reason });
|
|
46
70
|
context.ui.line(`paused: ${reason}`);
|
|
47
71
|
return 0;
|
|
48
72
|
}
|
|
@@ -53,7 +77,7 @@ function change(context, verb) {
|
|
|
53
77
|
}
|
|
54
78
|
if (verb === "broadcast") {
|
|
55
79
|
const message = text(context, verb);
|
|
56
|
-
store.broadcast.post({ by, text: message });
|
|
80
|
+
store.broadcast.post({ by: actor(context, store), text: message });
|
|
57
81
|
context.ui.line(`broadcast: ${message}`);
|
|
58
82
|
return 0;
|
|
59
83
|
}
|
|
@@ -74,4 +98,4 @@ export {
|
|
|
74
98
|
storeFrom,
|
|
75
99
|
change
|
|
76
100
|
};
|
|
77
|
-
//# sourceMappingURL=chunk-
|
|
101
|
+
//# sourceMappingURL=chunk-C3KRMTIZ.js.map
|
|
@@ -17,6 +17,37 @@ import {
|
|
|
17
17
|
|
|
18
18
|
// src/lease/config.ts
|
|
19
19
|
import { availableParallelism } from "os";
|
|
20
|
+
|
|
21
|
+
// src/lease/heavy-preset.ts
|
|
22
|
+
var SCRIPTS = ["test", "build", "typecheck"];
|
|
23
|
+
function scripts(manager, direct) {
|
|
24
|
+
return [
|
|
25
|
+
...direct.map((verb) => [manager, verb]),
|
|
26
|
+
...SCRIPTS.map((script) => [manager, "run", script])
|
|
27
|
+
];
|
|
28
|
+
}
|
|
29
|
+
var DEFAULT_HEAVY = [
|
|
30
|
+
["npm", "install"],
|
|
31
|
+
["npm", "i"],
|
|
32
|
+
["npm", "ci"],
|
|
33
|
+
["npm", "test"],
|
|
34
|
+
...scripts("npm", []),
|
|
35
|
+
["pnpm", "install"],
|
|
36
|
+
["pnpm", "i"],
|
|
37
|
+
...scripts("pnpm", SCRIPTS),
|
|
38
|
+
["yarn", "install"],
|
|
39
|
+
...scripts("yarn", SCRIPTS),
|
|
40
|
+
["bun", "install"],
|
|
41
|
+
["bun", "i"],
|
|
42
|
+
["bun", "test"],
|
|
43
|
+
...scripts("bun", []),
|
|
44
|
+
["cargo", "build"],
|
|
45
|
+
["cargo", "test"],
|
|
46
|
+
["cargo", "check"]
|
|
47
|
+
];
|
|
48
|
+
var HEAVY_PRESET = "default";
|
|
49
|
+
|
|
50
|
+
// src/lease/config.ts
|
|
20
51
|
var DISABLE_ENV = "PMCP_HEAVY_DISABLE";
|
|
21
52
|
var NOW_ENV = "PMCP_HEAVY_NOW";
|
|
22
53
|
var BUSY_EXIT = 75;
|
|
@@ -49,7 +80,8 @@ var KEYS = [
|
|
|
49
80
|
"io",
|
|
50
81
|
"usage_cap",
|
|
51
82
|
"settle_window",
|
|
52
|
-
"skip_always"
|
|
83
|
+
"skip_always",
|
|
84
|
+
"skip_reasons"
|
|
53
85
|
];
|
|
54
86
|
var SIZE = /^[1-9]\d*[KMGT]$/u;
|
|
55
87
|
function fail(path, message) {
|
|
@@ -178,12 +210,31 @@ function ioSettings(path, raw) {
|
|
|
178
210
|
}
|
|
179
211
|
return { enabled, weights, max };
|
|
180
212
|
}
|
|
181
|
-
|
|
213
|
+
var REASON = /^[a-z][a-z0-9_.:-]{0,63}$/u;
|
|
214
|
+
function reasons(path, key, value) {
|
|
182
215
|
if (value === void 0) return [];
|
|
183
|
-
if (!Array.isArray(value) || !value.every((item) => typeof item === "string" && item
|
|
184
|
-
fail(
|
|
216
|
+
if (!Array.isArray(value) || !value.every((item) => typeof item === "string" && REASON.test(item)))
|
|
217
|
+
fail(
|
|
218
|
+
path,
|
|
219
|
+
`[host.lease] ${key} must be a list of skip reasons: lower-case words such as "git-hook"`
|
|
220
|
+
);
|
|
185
221
|
return value;
|
|
186
222
|
}
|
|
223
|
+
function heavyList(path, value, declared) {
|
|
224
|
+
if (value === void 0) return declared ? [...DEFAULT_HEAVY] : [];
|
|
225
|
+
const items = value === HEAVY_PRESET ? [value] : value;
|
|
226
|
+
if (!Array.isArray(items))
|
|
227
|
+
fail(
|
|
228
|
+
path,
|
|
229
|
+
`[host.lease] heavy must be "${HEAVY_PRESET}" or a list of argv prefixes`
|
|
230
|
+
);
|
|
231
|
+
const preset = items.includes(HEAVY_PRESET);
|
|
232
|
+
const own = argvList(
|
|
233
|
+
path,
|
|
234
|
+
items.filter((item) => item !== HEAVY_PRESET)
|
|
235
|
+
);
|
|
236
|
+
return [...preset ? DEFAULT_HEAVY : [], ...own];
|
|
237
|
+
}
|
|
187
238
|
function hardFactor(path, value) {
|
|
188
239
|
if (value === void 0) return 2;
|
|
189
240
|
if (typeof value !== "number" || !(value >= 1))
|
|
@@ -192,7 +243,8 @@ function hardFactor(path, value) {
|
|
|
192
243
|
}
|
|
193
244
|
function readLeaseSettings(path, dir, host) {
|
|
194
245
|
const root = table(path, "host", host) ?? {};
|
|
195
|
-
const
|
|
246
|
+
const declared = child(path, root, "host", "lease");
|
|
247
|
+
const raw = declared ?? {};
|
|
196
248
|
const read = new Reader(path, "host.lease", raw, KEYS);
|
|
197
249
|
const memoryMax = memory(path, "host.lease", raw["memory_max"]);
|
|
198
250
|
const base = {
|
|
@@ -211,7 +263,8 @@ function readLeaseSettings(path, dir, host) {
|
|
|
211
263
|
markerEnv: read.envName("marker_env") ?? "PMCP_HEAVY_LEASE",
|
|
212
264
|
...legacyMarkerEnv ? { legacyMarkerEnv } : {},
|
|
213
265
|
...legacySkipEnv ? { legacySkipEnv } : {},
|
|
214
|
-
skipAlways: reasons(path, raw["skip_always"]),
|
|
266
|
+
skipAlways: reasons(path, "skip_always", raw["skip_always"]),
|
|
267
|
+
skipReasons: reasons(path, "skip_reasons", raw["skip_reasons"]),
|
|
215
268
|
maxLoad: read.positive("max_load") ?? availableParallelism(),
|
|
216
269
|
maxIo: read.positive("max_io") ?? 8,
|
|
217
270
|
ioWindow: read.oneOf("io_window", ["avg10", "avg60", "avg300"], "avg60"),
|
|
@@ -239,7 +292,7 @@ function readLeaseSettings(path, dir, host) {
|
|
|
239
292
|
tiny: argvList(path, raw["tiny"]),
|
|
240
293
|
perSession: whole(path, "host.lease", "per_session", raw["per_session"], 1),
|
|
241
294
|
profiles: profiles(path, child(path, raw, "host.lease", "profiles"), base),
|
|
242
|
-
heavy:
|
|
295
|
+
heavy: heavyList(path, raw["heavy"], declared !== void 0),
|
|
243
296
|
guard: read.oneOf("guard", ["observe", "warn", "deny", "off"], "observe"),
|
|
244
297
|
io: ioSettings(path, child(path, raw, "host.lease", "io")),
|
|
245
298
|
usageCap: read.int("usage_cap", 5e6),
|
|
@@ -266,4 +319,4 @@ export {
|
|
|
266
319
|
readLeaseSettings,
|
|
267
320
|
leaseSettingsFor
|
|
268
321
|
};
|
|
269
|
-
//# sourceMappingURL=chunk-
|
|
322
|
+
//# sourceMappingURL=chunk-DITIXBFB.js.map
|
|
@@ -3,7 +3,7 @@ import {
|
|
|
3
3
|
} from "./chunk-34DECPVC.js";
|
|
4
4
|
import {
|
|
5
5
|
ptyBinary
|
|
6
|
-
} from "./chunk-
|
|
6
|
+
} from "./chunk-2TXVOHRS.js";
|
|
7
7
|
import {
|
|
8
8
|
GroupStore,
|
|
9
9
|
egressPolicy,
|
|
@@ -775,4 +775,4 @@ export {
|
|
|
775
775
|
prepareBridge,
|
|
776
776
|
assertBridge
|
|
777
777
|
};
|
|
778
|
-
//# sourceMappingURL=chunk-
|
|
778
|
+
//# sourceMappingURL=chunk-DWHM5BAY.js.map
|
|
@@ -5,7 +5,7 @@ import {
|
|
|
5
5
|
POLICIES,
|
|
6
6
|
customMode,
|
|
7
7
|
customPolicy
|
|
8
|
-
} from "./chunk-
|
|
8
|
+
} from "./chunk-TOR6SKRB.js";
|
|
9
9
|
import {
|
|
10
10
|
RUNTIMES
|
|
11
11
|
} from "./chunk-ARXCYFFZ.js";
|
|
@@ -42,4 +42,4 @@ function policyRows(compiled) {
|
|
|
42
42
|
export {
|
|
43
43
|
policyRows
|
|
44
44
|
};
|
|
45
|
-
//# sourceMappingURL=chunk-
|
|
45
|
+
//# sourceMappingURL=chunk-EC5QLEZD.js.map
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import {
|
|
2
2
|
detect
|
|
3
|
-
} from "./chunk-
|
|
3
|
+
} from "./chunk-SDFJJJB5.js";
|
|
4
4
|
import {
|
|
5
5
|
readStoreSettings,
|
|
6
6
|
resolveLeaseFiles,
|
|
@@ -313,4 +313,4 @@ export {
|
|
|
313
313
|
gateTreePath,
|
|
314
314
|
leaseSpecs
|
|
315
315
|
};
|
|
316
|
-
//# sourceMappingURL=chunk-
|
|
316
|
+
//# sourceMappingURL=chunk-EWYLWBKS.js.map
|
|
@@ -6,7 +6,7 @@ import {
|
|
|
6
6
|
} from "./chunk-34DECPVC.js";
|
|
7
7
|
import {
|
|
8
8
|
ptyBinary
|
|
9
|
-
} from "./chunk-
|
|
9
|
+
} from "./chunk-2TXVOHRS.js";
|
|
10
10
|
|
|
11
11
|
// src/harness/adapters/systemd/admission.ts
|
|
12
12
|
var nativeHostTools = ["systemctl", "systemd-run"];
|
|
@@ -36,4 +36,4 @@ export {
|
|
|
36
36
|
nativeHostTools,
|
|
37
37
|
assertNativeHost
|
|
38
38
|
};
|
|
39
|
-
//# sourceMappingURL=chunk-
|
|
39
|
+
//# sourceMappingURL=chunk-ISWR2XIU.js.map
|
|
@@ -7,20 +7,20 @@ import {
|
|
|
7
7
|
observeSession,
|
|
8
8
|
openGroup,
|
|
9
9
|
runOperation
|
|
10
|
-
} from "./chunk-
|
|
10
|
+
} from "./chunk-3P6Y2BAO.js";
|
|
11
11
|
import {
|
|
12
12
|
nativeHostTools
|
|
13
|
-
} from "./chunk-
|
|
13
|
+
} from "./chunk-ISWR2XIU.js";
|
|
14
14
|
import {
|
|
15
15
|
locateExecutable
|
|
16
16
|
} from "./chunk-R2GPCZUX.js";
|
|
17
17
|
import {
|
|
18
18
|
artifact,
|
|
19
19
|
stateDirectory
|
|
20
|
-
} from "./chunk-
|
|
20
|
+
} from "./chunk-DWHM5BAY.js";
|
|
21
21
|
import {
|
|
22
22
|
ptyBinary
|
|
23
|
-
} from "./chunk-
|
|
23
|
+
} from "./chunk-2TXVOHRS.js";
|
|
24
24
|
import {
|
|
25
25
|
GroupStore,
|
|
26
26
|
privateJson
|
|
@@ -249,4 +249,4 @@ async function invoke(operation) {
|
|
|
249
249
|
export {
|
|
250
250
|
invoke
|
|
251
251
|
};
|
|
252
|
-
//# sourceMappingURL=chunk-
|
|
252
|
+
//# sourceMappingURL=chunk-LZVHFPN6.js.map
|
|
@@ -7,7 +7,7 @@ import {
|
|
|
7
7
|
prepare,
|
|
8
8
|
present,
|
|
9
9
|
writeNative
|
|
10
|
-
} from "./chunk-
|
|
10
|
+
} from "./chunk-SRSKCFFS.js";
|
|
11
11
|
import {
|
|
12
12
|
ANTIGRAVITY_MCP_PLUGIN,
|
|
13
13
|
BUNDLE_NATIVE_FILES,
|
|
@@ -21,7 +21,7 @@ import {
|
|
|
21
21
|
same,
|
|
22
22
|
splitKeyed,
|
|
23
23
|
withoutBlock
|
|
24
|
-
} from "./chunk-
|
|
24
|
+
} from "./chunk-TOR6SKRB.js";
|
|
25
25
|
import {
|
|
26
26
|
HOOK_DIRECTORY
|
|
27
27
|
} from "./chunk-ARXCYFFZ.js";
|
|
@@ -30,7 +30,7 @@ import {
|
|
|
30
30
|
replaceFile,
|
|
31
31
|
replaceLink,
|
|
32
32
|
writeLock
|
|
33
|
-
} from "./chunk-
|
|
33
|
+
} from "./chunk-2TXVOHRS.js";
|
|
34
34
|
import {
|
|
35
35
|
RULES_DIR,
|
|
36
36
|
legacyLinks
|
|
@@ -400,4 +400,4 @@ export {
|
|
|
400
400
|
unmanagedHooks,
|
|
401
401
|
describeHookProblem
|
|
402
402
|
};
|
|
403
|
-
//# sourceMappingURL=chunk-
|
|
403
|
+
//# sourceMappingURL=chunk-MBHI2TKQ.js.map
|
|
@@ -70,9 +70,9 @@ var heavySpec = {
|
|
|
70
70
|
{
|
|
71
71
|
name: "stats",
|
|
72
72
|
describe: "Recorded run times and weights per command",
|
|
73
|
-
usage: "pmcp heavy stats [--json]",
|
|
74
|
-
options: ["config", "json"],
|
|
75
|
-
examples: ["pmcp heavy stats"]
|
|
73
|
+
usage: "pmcp heavy stats [--top <n>] [--json]",
|
|
74
|
+
options: ["top", "config", "json"],
|
|
75
|
+
examples: ["pmcp heavy stats --top 10"]
|
|
76
76
|
}
|
|
77
77
|
],
|
|
78
78
|
describe: "Run a heavy command within the host-wide budget, by lane, once the host has room",
|
|
@@ -110,6 +110,11 @@ var heavySpec = {
|
|
|
110
110
|
describe: "cancel: also stop a job that is already running.",
|
|
111
111
|
boolean: true
|
|
112
112
|
},
|
|
113
|
+
{
|
|
114
|
+
name: "top",
|
|
115
|
+
describe: "stats: only the n commands with the most runs.",
|
|
116
|
+
placeholder: "<n>"
|
|
117
|
+
},
|
|
113
118
|
{
|
|
114
119
|
name: "ticket",
|
|
115
120
|
describe: "Internal: the submitted ticket this run belongs to.",
|
|
@@ -131,4 +136,4 @@ var heavySpec = {
|
|
|
131
136
|
export {
|
|
132
137
|
heavySpec
|
|
133
138
|
};
|
|
134
|
-
//# sourceMappingURL=chunk-
|
|
139
|
+
//# sourceMappingURL=chunk-NAHAESFV.js.map
|