replicas-cli 0.3.518 → 0.3.520
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 +109 -22
- package/package.json +1 -1
package/dist/index.cjs
CHANGED
|
@@ -24579,11 +24579,45 @@ replicas gpu delete
|
|
|
24579
24579
|
});
|
|
24580
24580
|
|
|
24581
24581
|
// ../shared/src/routes/issues.ts
|
|
24582
|
-
|
|
24582
|
+
function readUnknownIssueValues(parse3) {
|
|
24583
|
+
const unknown2 = [];
|
|
24584
|
+
unknownValues = unknown2;
|
|
24585
|
+
try {
|
|
24586
|
+
return { result: parse3(), unknown: unknown2 };
|
|
24587
|
+
} finally {
|
|
24588
|
+
unknownValues = null;
|
|
24589
|
+
}
|
|
24590
|
+
}
|
|
24591
|
+
function parseIssueContractRecord(schema, value, at, report) {
|
|
24592
|
+
const { result, unknown: unknown2 } = readUnknownIssueValues(() => external_exports.safeParse(schema, value, { reportInput: true }));
|
|
24593
|
+
if (result.success) {
|
|
24594
|
+
if (unknown2.length) report.kept++;
|
|
24595
|
+
for (const raw of unknown2) report.problems.add(`${at || "snapshot"} unknown_value ${raw.slice(0, 40)}`);
|
|
24596
|
+
return result.data;
|
|
24597
|
+
}
|
|
24598
|
+
for (const issue3 of result.error.issues) {
|
|
24599
|
+
const path12 = [at, ...issue3.path.map((key) => typeof key === "number" || UUID_RE.test(String(key)) ? "*" : String(key))].filter(Boolean).join(".");
|
|
24600
|
+
report.problems.add(`${path12} ${issue3.code}${issue3.code === "invalid_value" ? ` ${String(issue3.input).slice(0, 40)}` : ""}`);
|
|
24601
|
+
}
|
|
24602
|
+
report.dropped++;
|
|
24603
|
+
return void 0;
|
|
24604
|
+
}
|
|
24605
|
+
function parseIssueContractResponse(schema, value, report) {
|
|
24606
|
+
const rows = isRecord(value) ? Object.fromEntries(Object.entries(value).map(([key, raw]) => {
|
|
24607
|
+
const field2 = schema.shape[key];
|
|
24608
|
+
return [key, field2 instanceof external_exports.ZodArray && Array.isArray(raw) ? raw.filter((row) => parseIssueContractRecord(field2.element, row, key, report) !== void 0) : raw];
|
|
24609
|
+
})) : value;
|
|
24610
|
+
const parsed = external_exports.safeParse(schema, rows);
|
|
24611
|
+
if (!parsed.success) for (const issue3 of parsed.error.issues) report.problems.add(`${issue3.path.join(".")} ${issue3.code}`);
|
|
24612
|
+
return parsed.data;
|
|
24613
|
+
}
|
|
24614
|
+
var ISSUE_STATUSES, ISSUE_PRIORITIES, ISSUE_ACTOR_TYPES, ISSUE_SUBSCRIBER_ROLES, ISSUE_RELATION_TYPES, ISSUE_PULL_REQUEST_STATES, normalizeIssueStatus, ISSUE_STATUSES_HEADER, issueStatusSchema, issuePrioritySchema, issueSubscriberRoleSchema, issueRelationTypeSchema, issuePullRequestStateSchema, ISSUE_STATUS_LABELS, ISSUE_PRIORITY_LABELS, unknownValues, knownOrRaw, createIssueContractReport, knownIssueActorSchema, issueActorSchema, ISSUE_KEY_RE, timestamp, nullableTimestamp, issueSchema, issueSubscriberSchema, issueRelationSchema, issuePullRequestSchema, issueCommentSchema, change, nullableId, issueEventDataSchemas, issueEventBase, v, issueEventVariants, created, laterVariants, issueEventSchema, clientMutationId, title, description, body, createIssueRequestSchema, updateIssueRequestSchema, issueActorRequestSchema, createIssueCommentRequestSchema, updateIssueCommentRequestSchema, createIssueRelationRequestSchema, linkIssuePullRequestRequestSchema, updateIssuePullRequestRequestSchema, issueMutationRequestSchema, updateIssueSettingsRequestSchema, listIssuesQuerySchema, issueDetailResponseSchema, listIssuesResponseSchema, issueDirectoryUserSchema, issueDirectoryWorkspaceSchema, issuesBootstrapResponseSchema, issuesDeltaQuerySchema, issuesDeltaResponseSchema, issueInboxQuerySchema, markIssueInboxReadRequestSchema, ISSUE_COMMANDS;
|
|
24583
24615
|
var init_issues = __esm({
|
|
24584
24616
|
"../shared/src/routes/issues.ts"() {
|
|
24585
24617
|
"use strict";
|
|
24586
24618
|
init_zod();
|
|
24619
|
+
init_type_guards();
|
|
24620
|
+
init_uuid();
|
|
24587
24621
|
init_manager();
|
|
24588
24622
|
init_workspaces();
|
|
24589
24623
|
ISSUE_STATUSES = ["backlog", "todo", "in_progress", "review", "approved", "done", "canceled", "duplicate"];
|
|
@@ -24607,10 +24641,12 @@ var init_issues = __esm({
|
|
|
24607
24641
|
unknownValues?.push(value);
|
|
24608
24642
|
return true;
|
|
24609
24643
|
})]);
|
|
24610
|
-
|
|
24644
|
+
createIssueContractReport = () => ({ problems: /* @__PURE__ */ new Set(), dropped: 0, kept: 0 });
|
|
24645
|
+
knownIssueActorSchema = external_exports.object({
|
|
24611
24646
|
type: external_exports.enum(ISSUE_ACTOR_TYPES),
|
|
24612
24647
|
id: external_exports.string().toLowerCase().uuid()
|
|
24613
24648
|
});
|
|
24649
|
+
issueActorSchema = knownIssueActorSchema.extend({ type: knownOrRaw(knownIssueActorSchema.shape.type) });
|
|
24614
24650
|
ISSUE_KEY_RE = /^[A-Z][A-Z0-9]{0,9}$/;
|
|
24615
24651
|
timestamp = external_exports.string();
|
|
24616
24652
|
nullableTimestamp = timestamp.nullable();
|
|
@@ -24724,8 +24760,8 @@ var init_issues = __esm({
|
|
|
24724
24760
|
parent_id: external_exports.string().uuid().optional(),
|
|
24725
24761
|
manager_id: external_exports.string().uuid().optional(),
|
|
24726
24762
|
sort_order: external_exports.number().finite().optional(),
|
|
24727
|
-
assignees: external_exports.array(
|
|
24728
|
-
subscribers: external_exports.array(
|
|
24763
|
+
assignees: external_exports.array(knownIssueActorSchema).max(20).optional(),
|
|
24764
|
+
subscribers: external_exports.array(knownIssueActorSchema).max(50).optional(),
|
|
24729
24765
|
client_mutation_id: clientMutationId
|
|
24730
24766
|
});
|
|
24731
24767
|
updateIssueRequestSchema = external_exports.object({
|
|
@@ -24739,7 +24775,7 @@ var init_issues = __esm({
|
|
|
24739
24775
|
sort_order: external_exports.number().finite().optional(),
|
|
24740
24776
|
client_mutation_id: clientMutationId
|
|
24741
24777
|
});
|
|
24742
|
-
issueActorRequestSchema =
|
|
24778
|
+
issueActorRequestSchema = knownIssueActorSchema.partial().extend({ client_mutation_id: clientMutationId });
|
|
24743
24779
|
createIssueCommentRequestSchema = external_exports.object({
|
|
24744
24780
|
id: external_exports.string().uuid().optional(),
|
|
24745
24781
|
body,
|
|
@@ -27859,14 +27895,15 @@ var init_tag_blocks = __esm({
|
|
|
27859
27895
|
});
|
|
27860
27896
|
|
|
27861
27897
|
// ../shared/src/issue-events.ts
|
|
27862
|
-
function parseChange(line,
|
|
27898
|
+
function parseChange(line, quote) {
|
|
27863
27899
|
const match = line.match(CHANGE_LINE);
|
|
27864
27900
|
const rest = (match ? match[3] + match[4] : line).replaceAll(" (agent)", "").replace(/(?:\. Now)?:$/, "");
|
|
27865
27901
|
const [, field2, from, to] = rest.match(TRANSITION) ?? [];
|
|
27866
27902
|
const transition = transitionSchema.safeParse({ field: field2, from, to }).data;
|
|
27867
27903
|
const labels = !transition ? [] : transition.field === "status" ? [ISSUE_STATUS_LABELS[transition.from], ISSUE_STATUS_LABELS[transition.to]] : [ISSUE_PRIORITY_LABELS[transition.from], ISSUE_PRIORITY_LABELS[transition.to]];
|
|
27868
27904
|
const text4 = transition ? `changed the ${transition.field}: ${labels.join(" \u2192 ")}` : rest;
|
|
27869
|
-
|
|
27905
|
+
const excerpt = quote.split("\n").map((quoted) => quoted.trim()).find(Boolean);
|
|
27906
|
+
return { actor: match?.[1] ?? "", agent: Boolean(match?.[2]), text: excerpt ? `${text4}: ${excerpt}` : text4, ...quote ? { quote } : {}, ...transition ? { transition } : {} };
|
|
27870
27907
|
}
|
|
27871
27908
|
function extractIssueEvents(text4) {
|
|
27872
27909
|
return [...text4.matchAll(tagBlockPattern(ISSUE_EVENT_TAG))].flatMap((match) => {
|
|
@@ -27876,7 +27913,7 @@ function extractIssueEvents(text4) {
|
|
|
27876
27913
|
const changes = detail.split("\n\n").flatMap((paragraph) => {
|
|
27877
27914
|
const [line, ...quoted] = paragraph.split("\n");
|
|
27878
27915
|
if (!line.trim() || line.startsWith(">")) return [];
|
|
27879
|
-
return [parseChange(line,
|
|
27916
|
+
return [parseChange(line, quoted.map((quote) => quote.replace(/^>\s?/, "")).join("\n").trim())];
|
|
27880
27917
|
});
|
|
27881
27918
|
return [{
|
|
27882
27919
|
id: `${attributes.issue}:${attributes.sync_id ?? ""}`,
|
|
@@ -27902,7 +27939,7 @@ var init_issue_events = __esm({
|
|
|
27902
27939
|
external_exports.object({ field: external_exports.literal("status"), from: issueStatusSchema, to: issueStatusSchema }),
|
|
27903
27940
|
external_exports.object({ field: external_exports.literal("priority"), from: issuePrioritySchema, to: issuePrioritySchema })
|
|
27904
27941
|
]);
|
|
27905
|
-
issueEventChangeSchema = external_exports.object({ actor: external_exports.string(), agent: external_exports.boolean(), text: external_exports.string(), transition: transitionSchema.optional() });
|
|
27942
|
+
issueEventChangeSchema = external_exports.object({ actor: external_exports.string(), agent: external_exports.boolean(), text: external_exports.string(), quote: external_exports.string().optional(), transition: transitionSchema.optional() });
|
|
27906
27943
|
CHANGE_LINE = /^(.+?)( \(agent\))? (created it|renamed it|edited |changed the |made it|moved it|removed |assigned |unassigned |marked |linked |unlinked |pull request |commented|deleted a comment|archived it|restored it)(.*)$/;
|
|
27907
27944
|
TRANSITION = /^changed the (status|priority): (\w+) → (\w+)$/;
|
|
27908
27945
|
issueChangeSentence = (change2) => [change2.actor, change2.text].filter(Boolean).join(" ");
|
|
@@ -40202,7 +40239,7 @@ var CLI_VERSION;
|
|
|
40202
40239
|
var init_cli_version = __esm({
|
|
40203
40240
|
"../shared/src/cli-version.ts"() {
|
|
40204
40241
|
"use strict";
|
|
40205
|
-
CLI_VERSION = "0.3.
|
|
40242
|
+
CLI_VERSION = "0.3.520";
|
|
40206
40243
|
}
|
|
40207
40244
|
});
|
|
40208
40245
|
|
|
@@ -56394,6 +56431,46 @@ var init_preview = __esm({
|
|
|
56394
56431
|
}
|
|
56395
56432
|
});
|
|
56396
56433
|
|
|
56434
|
+
// ../shared/src/media-url.ts
|
|
56435
|
+
function readImageSize(read) {
|
|
56436
|
+
let bytes = read(0);
|
|
56437
|
+
let view = new DataView(bytes.buffer, bytes.byteOffset, bytes.byteLength);
|
|
56438
|
+
const ascii = (at, length) => String.fromCharCode(...bytes.subarray(at, at + length));
|
|
56439
|
+
const size = (width, height, exif2 = false) => width > 0 && height > 0 ? { width, height, exif: exif2 } : null;
|
|
56440
|
+
if (bytes.length >= 24 && ascii(1, 3) === "PNG") return size(view.getUint32(16), view.getUint32(20));
|
|
56441
|
+
if (bytes.length >= 10 && ascii(0, 3) === "GIF") return size(view.getUint16(6, true), view.getUint16(8, true));
|
|
56442
|
+
if (bytes.length >= 31 && ascii(0, 4) === "RIFF" && ascii(8, 4) === "WEBP") {
|
|
56443
|
+
const chunk = ascii(12, 4);
|
|
56444
|
+
if (chunk === "VP8X") return size(1 + (view.getUint32(24, true) & 16777215), 1 + (view.getUint32(27, true) & 16777215));
|
|
56445
|
+
if (chunk === "VP8 ") return size(view.getUint16(26, true) & 16383, view.getUint16(28, true) & 16383);
|
|
56446
|
+
if (chunk === "VP8L") {
|
|
56447
|
+
const bits = view.getUint32(21, true);
|
|
56448
|
+
return size(1 + (bits & 16383), 1 + (bits >> 14 & 16383));
|
|
56449
|
+
}
|
|
56450
|
+
return null;
|
|
56451
|
+
}
|
|
56452
|
+
if (bytes[0] !== 255 || bytes[1] !== 216) return null;
|
|
56453
|
+
let exif = false;
|
|
56454
|
+
for (let at = 2; ; ) {
|
|
56455
|
+
bytes = read(at);
|
|
56456
|
+
view = new DataView(bytes.buffer, bytes.byteOffset, bytes.byteLength);
|
|
56457
|
+
if (bytes.length < 9 || bytes[0] !== 255) return null;
|
|
56458
|
+
const marker = bytes[1];
|
|
56459
|
+
if (marker === 225) exif = true;
|
|
56460
|
+
if (marker >= 192 && marker <= 207 && marker !== 196 && marker !== 200 && marker !== 204) return size(view.getUint16(7), view.getUint16(5), exif);
|
|
56461
|
+
at += 2 + view.getUint16(2);
|
|
56462
|
+
}
|
|
56463
|
+
}
|
|
56464
|
+
var REPLICAS_WEB_ORIGIN, withImageSize;
|
|
56465
|
+
var init_media_url = __esm({
|
|
56466
|
+
"../shared/src/media-url.ts"() {
|
|
56467
|
+
"use strict";
|
|
56468
|
+
init_urls();
|
|
56469
|
+
REPLICAS_WEB_ORIGIN = new URL(DEFAULT_WEB_APP_URL).origin;
|
|
56470
|
+
withImageSize = (url2, size) => size ? `${url2}#w=${size.width}&h=${size.height}` : url2;
|
|
56471
|
+
}
|
|
56472
|
+
});
|
|
56473
|
+
|
|
56397
56474
|
// src/commands/media.ts
|
|
56398
56475
|
function publicMediaUrl(mediaId, token) {
|
|
56399
56476
|
return `${MONOLITH_URL}/v1/media/public/${mediaId}/${token}`;
|
|
@@ -56454,11 +56531,13 @@ async function uploadOne(filePath, displayName, kind, options) {
|
|
|
56454
56531
|
const fileName = import_path6.default.basename(absPath);
|
|
56455
56532
|
const ext = import_path6.default.extname(absPath).slice(1).toLowerCase();
|
|
56456
56533
|
const contentType = mediaInfo(ext)?.contentType ?? "application/octet-stream";
|
|
56457
|
-
|
|
56534
|
+
const body2 = import_fs7.default.readFileSync(absPath);
|
|
56535
|
+
const media2 = await uploadMedia(new Blob([body2], { type: contentType }), fileName, {
|
|
56458
56536
|
kind,
|
|
56459
56537
|
display_name: displayName,
|
|
56460
56538
|
session_id: options.sessionId || void 0
|
|
56461
56539
|
});
|
|
56540
|
+
return { media: media2, imageSize: kind === MEDIA_KIND.IMAGE ? readImageSize((offset) => body2.subarray(offset)) : null };
|
|
56462
56541
|
}
|
|
56463
56542
|
async function mediaUploadCommand(filePaths, options) {
|
|
56464
56543
|
if (filePaths.length === 0) {
|
|
@@ -56496,7 +56575,7 @@ async function mediaUploadCommand(filePaths, options) {
|
|
|
56496
56575
|
);
|
|
56497
56576
|
const shareResults = await Promise.allSettled(
|
|
56498
56577
|
results.map(
|
|
56499
|
-
(result, i) => result.status === "fulfilled" && shared[i] ? shareMedia(result.value.id) : Promise.resolve(null)
|
|
56578
|
+
(result, i) => result.status === "fulfilled" && shared[i] ? shareMedia(result.value.media.id) : Promise.resolve(null)
|
|
56500
56579
|
)
|
|
56501
56580
|
);
|
|
56502
56581
|
const config3 = readAgentConfig();
|
|
@@ -56505,7 +56584,7 @@ async function mediaUploadCommand(filePaths, options) {
|
|
|
56505
56584
|
for (let i = 0; i < results.length; i++) {
|
|
56506
56585
|
const result = results[i];
|
|
56507
56586
|
if (result.status === "fulfilled") {
|
|
56508
|
-
const media2 = result.value;
|
|
56587
|
+
const { media: media2, imageSize } = result.value;
|
|
56509
56588
|
const shareResult = shareResults[i];
|
|
56510
56589
|
const publicUrl = shareResult?.status === "fulfilled" ? shareResult.value ?? void 0 : void 0;
|
|
56511
56590
|
if (shared[i]) {
|
|
@@ -56525,7 +56604,7 @@ async function mediaUploadCommand(filePaths, options) {
|
|
|
56525
56604
|
name: names[i],
|
|
56526
56605
|
media: media2,
|
|
56527
56606
|
public_url: publicUrl,
|
|
56528
|
-
embed: !shared[i] || publicUrl ? formatMediaEmbed(names[i], media2, publicUrl) : void 0,
|
|
56607
|
+
embed: !shared[i] || publicUrl ? formatMediaEmbed(names[i], media2, publicUrl && withImageSize(publicUrl, imageSize && !imageSize.exif ? imageSize : null)) : void 0,
|
|
56529
56608
|
organization_url: options.access === "organization" && !shared[i] ? getOrganizationMediaUrl(media2.organization_id, media2.id) : void 0,
|
|
56530
56609
|
dashboard_url: config3?.workspace_id ? getWorkspaceDashboardUrl(config3.workspace_id, { mode: "media", mediaId: media2.id }) : void 0
|
|
56531
56610
|
});
|
|
@@ -56595,6 +56674,7 @@ var init_media3 = __esm({
|
|
|
56595
56674
|
init_api2();
|
|
56596
56675
|
init_config();
|
|
56597
56676
|
init_monolith_url();
|
|
56677
|
+
init_media_url();
|
|
56598
56678
|
init_output();
|
|
56599
56679
|
init_src();
|
|
56600
56680
|
MEDIA_ACCESS_VALUES = ["organization", "public"];
|
|
@@ -56694,18 +56774,24 @@ var init_media_gif = __esm({
|
|
|
56694
56774
|
// src/commands/issue.ts
|
|
56695
56775
|
async function callIssueTool(name, args, schema) {
|
|
56696
56776
|
if (!isAgentMode() && !getApiKey()) throw new Error("replicas issue needs an API key: run `replicas login --api-key`, or use it inside a workspace.");
|
|
56777
|
+
let response;
|
|
56697
56778
|
try {
|
|
56698
|
-
|
|
56779
|
+
response = await orgAuthenticatedFetch(`/v1/issue-commands/${name}`, { method: "POST", body: args, headers: { [ISSUE_STATUSES_HEADER]: "1" } });
|
|
56699
56780
|
} catch (error62) {
|
|
56700
56781
|
if (error62 instanceof ApiError && error62.status === 404 && error62.message === "Not found") throw new Error("Issues are not enabled for this organization");
|
|
56701
56782
|
throw error62;
|
|
56702
56783
|
}
|
|
56784
|
+
const report = createIssueContractReport();
|
|
56785
|
+
const parsed = parseIssueContractResponse(schema, response, report);
|
|
56786
|
+
if (parsed === void 0) throw new Error(`Unexpected response from the server: ${[...report.problems].join("; ")}`);
|
|
56787
|
+
if (report.dropped) console.error(import_chalk29.default.yellow(`Skipped ${report.dropped} record(s) this CLI can't read: ${[...report.problems].filter((problem) => !problem.includes("unknown_value")).join("; ")}`));
|
|
56788
|
+
return parsed;
|
|
56703
56789
|
}
|
|
56704
56790
|
async function uploadAttachments(files) {
|
|
56705
56791
|
if (!files?.length) return void 0;
|
|
56706
56792
|
if (!isAgentMode()) throw new Error("--attach works inside a workspace. Elsewhere, embed an image URL in the markdown.");
|
|
56707
56793
|
const uploaded = await Promise.all(files.map((file2) => uploadOne(file2, import_node_path2.default.basename(file2), resolveKind(import_node_path2.default.extname(file2).slice(1).toLowerCase()), {})));
|
|
56708
|
-
return uploaded.map((media2) => media2.id);
|
|
56794
|
+
return uploaded.map(({ media: media2 }) => media2.id);
|
|
56709
56795
|
}
|
|
56710
56796
|
function readText(inline, file2, what) {
|
|
56711
56797
|
if (inline !== void 0 && file2 !== void 0) throw new Error(`Pass either --${what} or --${what}-file, not both`);
|
|
@@ -56775,23 +56861,23 @@ async function issueCommentCommand(issue3, body2, options) {
|
|
|
56775
56861
|
const text4 = readText(body2, options.file, "file") ?? "";
|
|
56776
56862
|
const media_ids = await uploadAttachments(options.attach);
|
|
56777
56863
|
if (!text4.trim() && !media_ids) throw new Error("Pass the comment text, --file, or --attach");
|
|
56778
|
-
output2(await callIssueTool(ISSUE_COMMANDS.comment, { issue: issue3, body: text4, media_ids },
|
|
56864
|
+
output2(await callIssueTool(ISSUE_COMMANDS.comment, { issue: issue3, body: text4, media_ids }, noData), () => console.log(`${import_chalk29.default.green("\u2713")} Commented on ${issue3}`));
|
|
56779
56865
|
}
|
|
56780
56866
|
function issueActorCommand(tool, done) {
|
|
56781
56867
|
return async (issue3, who) => {
|
|
56782
|
-
output2(await callIssueTool(tool, { issue: issue3, who },
|
|
56868
|
+
output2(await callIssueTool(tool, { issue: issue3, who }, noData), () => console.log(`${import_chalk29.default.green("\u2713")} ${done} ${who ?? "you"} ${tool.startsWith("un") ? "from" : "to"} ${issue3}`));
|
|
56783
56869
|
};
|
|
56784
56870
|
}
|
|
56785
56871
|
async function issueLinkPrCommand(issue3, url2) {
|
|
56786
|
-
output2(await callIssueTool(ISSUE_COMMANDS.linkPr, { issue: issue3, url: url2 },
|
|
56872
|
+
output2(await callIssueTool(ISSUE_COMMANDS.linkPr, { issue: issue3, url: url2 }, noData), () => console.log(`${import_chalk29.default.green("\u2713")} Linked ${url2} to ${issue3}`));
|
|
56787
56873
|
}
|
|
56788
56874
|
async function issueUnlinkPrCommand(issue3, url2) {
|
|
56789
|
-
output2(await callIssueTool(ISSUE_COMMANDS.unlinkPr, { issue: issue3, url: url2 },
|
|
56875
|
+
output2(await callIssueTool(ISSUE_COMMANDS.unlinkPr, { issue: issue3, url: url2 }, noData), () => console.log(`${import_chalk29.default.green("\u2713")} Unlinked ${url2} from ${issue3}`));
|
|
56790
56876
|
}
|
|
56791
56877
|
async function issueRelateCommand(issue3, type, related) {
|
|
56792
|
-
output2(await callIssueTool(ISSUE_COMMANDS.relate, { issue: issue3, type, related_issue: related },
|
|
56878
|
+
output2(await callIssueTool(ISSUE_COMMANDS.relate, { issue: issue3, type, related_issue: related }, noData), () => console.log(`${import_chalk29.default.green("\u2713")} ${issue3} ${type.replace("_", " ")} ${related}`));
|
|
56793
56879
|
}
|
|
56794
|
-
var import_node_fs2, import_node_path2, import_chalk29, mutationSchema, csv, printMutation;
|
|
56880
|
+
var import_node_fs2, import_node_path2, import_chalk29, mutationSchema, noData, csv, printMutation;
|
|
56795
56881
|
var init_issue = __esm({
|
|
56796
56882
|
"src/commands/issue.ts"() {
|
|
56797
56883
|
"use strict";
|
|
@@ -56805,6 +56891,7 @@ var init_issue = __esm({
|
|
|
56805
56891
|
init_output();
|
|
56806
56892
|
init_media3();
|
|
56807
56893
|
mutationSchema = external_exports.object({ issue: issueSchema });
|
|
56894
|
+
noData = external_exports.looseObject({});
|
|
56808
56895
|
csv = (value) => value?.split(",").map((entry) => entry.trim()).filter(Boolean).join(",");
|
|
56809
56896
|
printMutation = ({ issue: issue3 }) => console.log(`${import_chalk29.default.green("\u2713")} ${import_chalk29.default.cyan(issue3.identifier)} ${issue3.title} (${issue3.status})`);
|
|
56810
56897
|
}
|