replicas-cli 0.3.316 → 0.3.318
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/dist/index.cjs +123 -121
- package/package.json +1 -1
package/dist/index.cjs
CHANGED
|
@@ -20739,6 +20739,7 @@ var init_preferences = __esm({
|
|
|
20739
20739
|
appshot_destination: "automatic",
|
|
20740
20740
|
appshot_sound: true,
|
|
20741
20741
|
mothership_tour_seen: false,
|
|
20742
|
+
mothership_board_opened: false,
|
|
20742
20743
|
follow_up_mode: "steer",
|
|
20743
20744
|
memory_enabled: null,
|
|
20744
20745
|
subagent_mcp_enabled: null,
|
|
@@ -28995,6 +28996,126 @@ var init_workspace_target = __esm({
|
|
|
28995
28996
|
}
|
|
28996
28997
|
});
|
|
28997
28998
|
|
|
28999
|
+
// ../shared/src/mothership-board.ts
|
|
29000
|
+
var MOTHERSHIP_BOARD_TONES, label, tone, blockId, httpsUrl, prUrl, linearIdentifier, action, text3, badge, pr, ship, linear, button, steps, inline, row, blockTypes, blockSchemas, block, MOTHERSHIP_BOARD_CONTAINER_TYPES, mothershipBoardBlocksSchema, mothershipBoardOperationsSchema, mothershipBoardItemRefSchema, LINEAR_ISSUE_SUMMARIES_MAX, linearIssueSummariesRequestSchema;
|
|
29001
|
+
var init_mothership_board = __esm({
|
|
29002
|
+
"../shared/src/mothership-board.ts"() {
|
|
29003
|
+
"use strict";
|
|
29004
|
+
init_zod();
|
|
29005
|
+
init_urls();
|
|
29006
|
+
MOTHERSHIP_BOARD_TONES = ["neutral", "needs_you", "warning", "success", "danger", "working"];
|
|
29007
|
+
label = (max) => external_exports.string().trim().min(1).max(max);
|
|
29008
|
+
tone = external_exports.enum(MOTHERSHIP_BOARD_TONES);
|
|
29009
|
+
blockId = external_exports.string().regex(/^[\w.:-]{1,64}$/, "Use 1-64 letters, digits, _, -, . or :");
|
|
29010
|
+
httpsUrl = external_exports.url({ protocol: /^https$/, error: "Must be an https URL" });
|
|
29011
|
+
prUrl = httpsUrl.refine((url2) => parseCodeHostPrUrl(url2) !== null, "Must be a GitHub pull request or GitLab merge request URL");
|
|
29012
|
+
linearIdentifier = external_exports.string().regex(/^[A-Za-z][A-Za-z0-9]{0,9}-\d{1,7}$/, "Use a Linear identifier such as REP-123");
|
|
29013
|
+
action = external_exports.discriminatedUnion("type", [
|
|
29014
|
+
external_exports.object({ type: external_exports.literal("open_ship"), workspace_id: external_exports.uuid() }),
|
|
29015
|
+
external_exports.object({ type: external_exports.literal("message_ship"), workspace_id: external_exports.uuid(), message: label(4e3) }),
|
|
29016
|
+
external_exports.object({ type: external_exports.literal("open_pr"), url: prUrl }),
|
|
29017
|
+
external_exports.object({ type: external_exports.literal("merge_pr"), url: prUrl }),
|
|
29018
|
+
external_exports.object({ type: external_exports.literal("message_mothership"), message: label(4e3) }),
|
|
29019
|
+
external_exports.object({ type: external_exports.literal("open_link"), url: httpsUrl })
|
|
29020
|
+
]);
|
|
29021
|
+
text3 = external_exports.object({ type: external_exports.literal("text"), id: blockId.optional(), text: label(2e3) });
|
|
29022
|
+
badge = external_exports.object({ type: external_exports.literal("badge"), id: blockId.optional(), label: label(40), tone: tone.optional() });
|
|
29023
|
+
pr = external_exports.object({ type: external_exports.literal("pr"), id: blockId.optional(), url: prUrl });
|
|
29024
|
+
ship = external_exports.object({ type: external_exports.literal("ship"), id: blockId.optional(), workspace_id: external_exports.uuid() });
|
|
29025
|
+
linear = external_exports.object({ type: external_exports.literal("linear"), id: blockId.optional(), identifier: linearIdentifier });
|
|
29026
|
+
button = external_exports.object({ type: external_exports.literal("button"), id: blockId.optional(), label: label(60), action, variant: external_exports.enum(["primary", "outline", "warning", "destructive"]).optional(), resolves: blockId.optional() });
|
|
29027
|
+
steps = external_exports.object({
|
|
29028
|
+
type: external_exports.literal("steps"),
|
|
29029
|
+
id: blockId.optional(),
|
|
29030
|
+
steps: external_exports.array(external_exports.object({ label: label(30), state: external_exports.enum(["done", "current", "pending", "failed"]) })).min(1).max(8)
|
|
29031
|
+
});
|
|
29032
|
+
inline = external_exports.discriminatedUnion("type", [text3, badge, pr, ship, linear, button, steps]);
|
|
29033
|
+
row = external_exports.object({ type: external_exports.literal("row"), id: blockId.optional(), cells: external_exports.array(external_exports.union([label(500), inline])).min(1).max(6) });
|
|
29034
|
+
blockTypes = {
|
|
29035
|
+
text: text3,
|
|
29036
|
+
badge,
|
|
29037
|
+
pr,
|
|
29038
|
+
ship,
|
|
29039
|
+
linear,
|
|
29040
|
+
button,
|
|
29041
|
+
steps,
|
|
29042
|
+
stat: external_exports.object({ type: external_exports.literal("stat"), id: blockId.optional(), label: label(40), value: label(40), tone: tone.optional() }),
|
|
29043
|
+
divider: external_exports.object({ type: external_exports.literal("divider"), id: blockId.optional() }),
|
|
29044
|
+
updated_at: external_exports.object({ type: external_exports.literal("updated_at"), id: blockId.optional() }),
|
|
29045
|
+
choice: external_exports.object({
|
|
29046
|
+
type: external_exports.literal("choice"),
|
|
29047
|
+
id: blockId.optional(),
|
|
29048
|
+
question: label(500),
|
|
29049
|
+
options: external_exports.array(external_exports.object({ label: label(60), message: label(2e3).optional() })).min(2).max(6),
|
|
29050
|
+
resolves: blockId.optional()
|
|
29051
|
+
}),
|
|
29052
|
+
button_group: external_exports.object({ type: external_exports.literal("button_group"), id: blockId.optional(), children: external_exports.array(button).min(1).max(8) }),
|
|
29053
|
+
table: external_exports.object({ type: external_exports.literal("table"), id: blockId.optional(), columns: external_exports.array(label(40)).min(1).max(6), children: external_exports.array(row).max(100) }),
|
|
29054
|
+
callout: external_exports.object({
|
|
29055
|
+
type: external_exports.literal("callout"),
|
|
29056
|
+
id: blockId.optional(),
|
|
29057
|
+
tone,
|
|
29058
|
+
title: label(120).optional(),
|
|
29059
|
+
get children() {
|
|
29060
|
+
return external_exports.array(block).max(20).optional();
|
|
29061
|
+
}
|
|
29062
|
+
}),
|
|
29063
|
+
list: external_exports.object({
|
|
29064
|
+
type: external_exports.literal("list"),
|
|
29065
|
+
id: blockId.optional(),
|
|
29066
|
+
ordered: external_exports.boolean().optional(),
|
|
29067
|
+
get children() {
|
|
29068
|
+
return external_exports.array(block).max(100);
|
|
29069
|
+
}
|
|
29070
|
+
}),
|
|
29071
|
+
section: external_exports.object({
|
|
29072
|
+
type: external_exports.literal("section"),
|
|
29073
|
+
id: blockId.optional(),
|
|
29074
|
+
title: label(120),
|
|
29075
|
+
tone: tone.optional(),
|
|
29076
|
+
collapsed: external_exports.boolean().optional(),
|
|
29077
|
+
get children() {
|
|
29078
|
+
return external_exports.array(block).max(100);
|
|
29079
|
+
}
|
|
29080
|
+
})
|
|
29081
|
+
};
|
|
29082
|
+
blockSchemas = [text3, ...Object.values(blockTypes).filter((schema) => schema !== text3)];
|
|
29083
|
+
block = external_exports.discriminatedUnion("type", blockSchemas);
|
|
29084
|
+
MOTHERSHIP_BOARD_CONTAINER_TYPES = Object.entries(blockTypes).filter(([, schema]) => "children" in schema.shape).map(([type]) => type);
|
|
29085
|
+
mothershipBoardBlocksSchema = external_exports.array(block).max(100).superRefine((blocks, ctx) => {
|
|
29086
|
+
const seen = /* @__PURE__ */ new Set();
|
|
29087
|
+
const visit = (node, path10) => {
|
|
29088
|
+
if (typeof node === "string") return;
|
|
29089
|
+
if (node.id) {
|
|
29090
|
+
if (seen.has(node.id)) ctx.addIssue({ code: "custom", path: [...path10, "id"], message: `Duplicate block id "${node.id}"` });
|
|
29091
|
+
seen.add(node.id);
|
|
29092
|
+
}
|
|
29093
|
+
if (node.type === "table") {
|
|
29094
|
+
node.children.forEach((child, index) => {
|
|
29095
|
+
if (child.cells.length > node.columns.length) ctx.addIssue({ code: "custom", path: [...path10, "children", index, "cells"], message: `Row has ${child.cells.length} cells but the table has ${node.columns.length} columns` });
|
|
29096
|
+
});
|
|
29097
|
+
}
|
|
29098
|
+
if (node.type === "row") node.cells.forEach((cell, index) => visit(cell, [...path10, "cells", index]));
|
|
29099
|
+
else if ("children" in node) node.children?.forEach((child, index) => visit(child, [...path10, "children", index]));
|
|
29100
|
+
};
|
|
29101
|
+
blocks.forEach((node, index) => visit(node, [index]));
|
|
29102
|
+
});
|
|
29103
|
+
mothershipBoardOperationsSchema = external_exports.array(external_exports.discriminatedUnion("op", [
|
|
29104
|
+
external_exports.object({ op: external_exports.literal("replace"), blocks: external_exports.array(block) }),
|
|
29105
|
+
external_exports.object({
|
|
29106
|
+
op: external_exports.literal("upsert"),
|
|
29107
|
+
block: external_exports.discriminatedUnion("type", [row, ...blockSchemas]).refine((value) => Boolean(value.id), { message: "Give the block an id", path: ["id"] }),
|
|
29108
|
+
parent_id: blockId.optional(),
|
|
29109
|
+
position: external_exports.number().int().min(0).optional()
|
|
29110
|
+
}),
|
|
29111
|
+
external_exports.object({ op: external_exports.literal("remove"), id: blockId })
|
|
29112
|
+
])).min(1).max(50);
|
|
29113
|
+
mothershipBoardItemRefSchema = external_exports.object({ mothershipId: external_exports.uuid(), block, occurrence: external_exports.number().int().min(0).optional() });
|
|
29114
|
+
LINEAR_ISSUE_SUMMARIES_MAX = 50;
|
|
29115
|
+
linearIssueSummariesRequestSchema = external_exports.object({ identifiers: external_exports.array(linearIdentifier).min(1).max(LINEAR_ISSUE_SUMMARIES_MAX) });
|
|
29116
|
+
}
|
|
29117
|
+
});
|
|
29118
|
+
|
|
28998
29119
|
// ../shared/src/user-message-matching.ts
|
|
28999
29120
|
function parseTimestampMs(timestamp) {
|
|
29000
29121
|
if (typeof timestamp === "number") return Number.isFinite(timestamp) ? timestamp : 0;
|
|
@@ -29050,6 +29171,7 @@ var init_steps = __esm({
|
|
|
29050
29171
|
init_utils();
|
|
29051
29172
|
init_subagent_tools();
|
|
29052
29173
|
init_tool_call();
|
|
29174
|
+
init_mothership_board();
|
|
29053
29175
|
init_turns();
|
|
29054
29176
|
SUBAGENT_STEPS = {
|
|
29055
29177
|
[SUBAGENT_MCP_TOOLS.messageAgent]: { icon: "message", live: "Messaging", done: "Messaged" },
|
|
@@ -31979,7 +32101,7 @@ var CLI_VERSION;
|
|
|
31979
32101
|
var init_cli_version = __esm({
|
|
31980
32102
|
"../shared/src/cli-version.ts"() {
|
|
31981
32103
|
"use strict";
|
|
31982
|
-
CLI_VERSION = "0.3.
|
|
32104
|
+
CLI_VERSION = "0.3.317";
|
|
31983
32105
|
}
|
|
31984
32106
|
});
|
|
31985
32107
|
|
|
@@ -42610,126 +42732,6 @@ var init_websocket_liveness = __esm({
|
|
|
42610
42732
|
}
|
|
42611
42733
|
});
|
|
42612
42734
|
|
|
42613
|
-
// ../shared/src/mothership-board.ts
|
|
42614
|
-
var MOTHERSHIP_BOARD_TONES, label, tone, blockId, httpsUrl, prUrl, linearIdentifier, action, text3, badge, pr, ship, linear, button, steps, inline, row, blockTypes, blockSchemas, block, MOTHERSHIP_BOARD_CONTAINER_TYPES, mothershipBoardBlocksSchema, mothershipBoardOperationsSchema, mothershipBoardItemRefSchema, LINEAR_ISSUE_SUMMARIES_MAX, linearIssueSummariesRequestSchema;
|
|
42615
|
-
var init_mothership_board = __esm({
|
|
42616
|
-
"../shared/src/mothership-board.ts"() {
|
|
42617
|
-
"use strict";
|
|
42618
|
-
init_zod();
|
|
42619
|
-
init_urls();
|
|
42620
|
-
MOTHERSHIP_BOARD_TONES = ["neutral", "needs_you", "warning", "success", "danger", "working"];
|
|
42621
|
-
label = (max) => external_exports.string().trim().min(1).max(max);
|
|
42622
|
-
tone = external_exports.enum(MOTHERSHIP_BOARD_TONES);
|
|
42623
|
-
blockId = external_exports.string().regex(/^[\w.:-]{1,64}$/, "Use 1-64 letters, digits, _, -, . or :");
|
|
42624
|
-
httpsUrl = external_exports.url({ protocol: /^https$/, error: "Must be an https URL" });
|
|
42625
|
-
prUrl = httpsUrl.refine((url2) => parseCodeHostPrUrl(url2) !== null, "Must be a GitHub pull request or GitLab merge request URL");
|
|
42626
|
-
linearIdentifier = external_exports.string().regex(/^[A-Za-z][A-Za-z0-9]{0,9}-\d{1,7}$/, "Use a Linear identifier such as REP-123");
|
|
42627
|
-
action = external_exports.discriminatedUnion("type", [
|
|
42628
|
-
external_exports.object({ type: external_exports.literal("open_ship"), workspace_id: external_exports.uuid() }),
|
|
42629
|
-
external_exports.object({ type: external_exports.literal("message_ship"), workspace_id: external_exports.uuid(), message: label(4e3) }),
|
|
42630
|
-
external_exports.object({ type: external_exports.literal("open_pr"), url: prUrl }),
|
|
42631
|
-
external_exports.object({ type: external_exports.literal("merge_pr"), url: prUrl }),
|
|
42632
|
-
external_exports.object({ type: external_exports.literal("message_mothership"), message: label(4e3) }),
|
|
42633
|
-
external_exports.object({ type: external_exports.literal("open_link"), url: httpsUrl })
|
|
42634
|
-
]);
|
|
42635
|
-
text3 = external_exports.object({ type: external_exports.literal("text"), id: blockId.optional(), text: label(2e3) });
|
|
42636
|
-
badge = external_exports.object({ type: external_exports.literal("badge"), id: blockId.optional(), label: label(40), tone: tone.optional() });
|
|
42637
|
-
pr = external_exports.object({ type: external_exports.literal("pr"), id: blockId.optional(), url: prUrl });
|
|
42638
|
-
ship = external_exports.object({ type: external_exports.literal("ship"), id: blockId.optional(), workspace_id: external_exports.uuid() });
|
|
42639
|
-
linear = external_exports.object({ type: external_exports.literal("linear"), id: blockId.optional(), identifier: linearIdentifier });
|
|
42640
|
-
button = external_exports.object({ type: external_exports.literal("button"), id: blockId.optional(), label: label(60), action, variant: external_exports.enum(["primary", "outline", "warning", "destructive"]).optional(), resolves: blockId.optional() });
|
|
42641
|
-
steps = external_exports.object({
|
|
42642
|
-
type: external_exports.literal("steps"),
|
|
42643
|
-
id: blockId.optional(),
|
|
42644
|
-
steps: external_exports.array(external_exports.object({ label: label(30), state: external_exports.enum(["done", "current", "pending", "failed"]) })).min(1).max(8)
|
|
42645
|
-
});
|
|
42646
|
-
inline = external_exports.discriminatedUnion("type", [text3, badge, pr, ship, linear, button, steps]);
|
|
42647
|
-
row = external_exports.object({ type: external_exports.literal("row"), id: blockId.optional(), cells: external_exports.array(external_exports.union([label(500), inline])).min(1).max(6) });
|
|
42648
|
-
blockTypes = {
|
|
42649
|
-
text: text3,
|
|
42650
|
-
badge,
|
|
42651
|
-
pr,
|
|
42652
|
-
ship,
|
|
42653
|
-
linear,
|
|
42654
|
-
button,
|
|
42655
|
-
steps,
|
|
42656
|
-
stat: external_exports.object({ type: external_exports.literal("stat"), id: blockId.optional(), label: label(40), value: label(40), tone: tone.optional() }),
|
|
42657
|
-
divider: external_exports.object({ type: external_exports.literal("divider"), id: blockId.optional() }),
|
|
42658
|
-
updated_at: external_exports.object({ type: external_exports.literal("updated_at"), id: blockId.optional() }),
|
|
42659
|
-
choice: external_exports.object({
|
|
42660
|
-
type: external_exports.literal("choice"),
|
|
42661
|
-
id: blockId.optional(),
|
|
42662
|
-
question: label(500),
|
|
42663
|
-
options: external_exports.array(external_exports.object({ label: label(60), message: label(2e3).optional() })).min(2).max(6),
|
|
42664
|
-
resolves: blockId.optional()
|
|
42665
|
-
}),
|
|
42666
|
-
button_group: external_exports.object({ type: external_exports.literal("button_group"), id: blockId.optional(), children: external_exports.array(button).min(1).max(8) }),
|
|
42667
|
-
table: external_exports.object({ type: external_exports.literal("table"), id: blockId.optional(), columns: external_exports.array(label(40)).min(1).max(6), children: external_exports.array(row).max(100) }),
|
|
42668
|
-
callout: external_exports.object({
|
|
42669
|
-
type: external_exports.literal("callout"),
|
|
42670
|
-
id: blockId.optional(),
|
|
42671
|
-
tone,
|
|
42672
|
-
title: label(120).optional(),
|
|
42673
|
-
get children() {
|
|
42674
|
-
return external_exports.array(block).max(20).optional();
|
|
42675
|
-
}
|
|
42676
|
-
}),
|
|
42677
|
-
list: external_exports.object({
|
|
42678
|
-
type: external_exports.literal("list"),
|
|
42679
|
-
id: blockId.optional(),
|
|
42680
|
-
ordered: external_exports.boolean().optional(),
|
|
42681
|
-
get children() {
|
|
42682
|
-
return external_exports.array(block).max(100);
|
|
42683
|
-
}
|
|
42684
|
-
}),
|
|
42685
|
-
section: external_exports.object({
|
|
42686
|
-
type: external_exports.literal("section"),
|
|
42687
|
-
id: blockId.optional(),
|
|
42688
|
-
title: label(120),
|
|
42689
|
-
tone: tone.optional(),
|
|
42690
|
-
collapsed: external_exports.boolean().optional(),
|
|
42691
|
-
get children() {
|
|
42692
|
-
return external_exports.array(block).max(100);
|
|
42693
|
-
}
|
|
42694
|
-
})
|
|
42695
|
-
};
|
|
42696
|
-
blockSchemas = [text3, ...Object.values(blockTypes).filter((schema) => schema !== text3)];
|
|
42697
|
-
block = external_exports.discriminatedUnion("type", blockSchemas);
|
|
42698
|
-
MOTHERSHIP_BOARD_CONTAINER_TYPES = Object.entries(blockTypes).filter(([, schema]) => "children" in schema.shape).map(([type]) => type);
|
|
42699
|
-
mothershipBoardBlocksSchema = external_exports.array(block).max(100).superRefine((blocks, ctx) => {
|
|
42700
|
-
const seen = /* @__PURE__ */ new Set();
|
|
42701
|
-
const visit = (node, path10) => {
|
|
42702
|
-
if (typeof node === "string") return;
|
|
42703
|
-
if (node.id) {
|
|
42704
|
-
if (seen.has(node.id)) ctx.addIssue({ code: "custom", path: [...path10, "id"], message: `Duplicate block id "${node.id}"` });
|
|
42705
|
-
seen.add(node.id);
|
|
42706
|
-
}
|
|
42707
|
-
if (node.type === "table") {
|
|
42708
|
-
node.children.forEach((child, index) => {
|
|
42709
|
-
if (child.cells.length > node.columns.length) ctx.addIssue({ code: "custom", path: [...path10, "children", index, "cells"], message: `Row has ${child.cells.length} cells but the table has ${node.columns.length} columns` });
|
|
42710
|
-
});
|
|
42711
|
-
}
|
|
42712
|
-
if (node.type === "row") node.cells.forEach((cell, index) => visit(cell, [...path10, "cells", index]));
|
|
42713
|
-
else if ("children" in node) node.children?.forEach((child, index) => visit(child, [...path10, "children", index]));
|
|
42714
|
-
};
|
|
42715
|
-
blocks.forEach((node, index) => visit(node, [index]));
|
|
42716
|
-
});
|
|
42717
|
-
mothershipBoardOperationsSchema = external_exports.array(external_exports.discriminatedUnion("op", [
|
|
42718
|
-
external_exports.object({ op: external_exports.literal("replace"), blocks: external_exports.array(block) }),
|
|
42719
|
-
external_exports.object({
|
|
42720
|
-
op: external_exports.literal("upsert"),
|
|
42721
|
-
block: external_exports.discriminatedUnion("type", [row, ...blockSchemas]).refine((value) => Boolean(value.id), { message: "Give the block an id", path: ["id"] }),
|
|
42722
|
-
parent_id: blockId.optional(),
|
|
42723
|
-
position: external_exports.number().int().min(0).optional()
|
|
42724
|
-
}),
|
|
42725
|
-
external_exports.object({ op: external_exports.literal("remove"), id: blockId })
|
|
42726
|
-
])).min(1).max(50);
|
|
42727
|
-
mothershipBoardItemRefSchema = external_exports.object({ mothershipId: external_exports.uuid(), block, occurrence: external_exports.number().int().min(0).optional() });
|
|
42728
|
-
LINEAR_ISSUE_SUMMARIES_MAX = 50;
|
|
42729
|
-
linearIssueSummariesRequestSchema = external_exports.object({ identifiers: external_exports.array(linearIdentifier).min(1).max(LINEAR_ISSUE_SUMMARIES_MAX) });
|
|
42730
|
-
}
|
|
42731
|
-
});
|
|
42732
|
-
|
|
42733
42735
|
// ../shared/src/index.ts
|
|
42734
42736
|
var init_src = __esm({
|
|
42735
42737
|
"../shared/src/index.ts"() {
|