@pome-sh/cli 0.21.5 → 0.21.7
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/build-info.json +3 -3
- package/dist/{checks-2AIHHQC2.js → checks-4GJB73YX.js} +1 -1
- package/dist/{chunk-CLGRZY53.js → chunk-4ILBTPO4.js} +4 -4
- package/dist/chunk-5ETJZJR6.js +590 -0
- package/dist/{chunk-MBM7LY7E.js → chunk-A3IDZXJY.js} +9 -9
- package/dist/chunk-FKZZWWYC.js +4 -0
- package/dist/{chunk-OMVRPIBP.js → chunk-JULH5ECU.js} +1 -1
- package/dist/{chunk-JQQPZQOJ.js → chunk-M3X6OT4N.js} +1 -1
- package/dist/chunk-NJ246QPJ.js +683 -0
- package/dist/chunk-SGDUD7KK.js +138 -0
- package/dist/{chunk-NWXONLFF.js → chunk-WR7KP3LE.js} +2 -2
- package/dist/chunk-XS66ZRBJ.js +537 -0
- package/dist/chunk-ZKID2HS3.js +628 -0
- package/dist/{runDemo-M3GEOJLT.js → runDemo-BCB6EDDN.js} +7 -8
- package/dist/{runTrialGroup-QQNDVHMR.js → runTrialGroup-YCSGW56C.js} +6 -7
- package/dist/src/cli/main.js +20 -16
- package/dist/{chunk-WVWV7DLA.js → src-FLTYWM6P.js} +500 -1761
- package/dist/{chunk-APAS34RJ.js → src-K3KTJTMG.js} +154 -1308
- package/dist/{chunk-OKDJRKJV.js → src-RVUEXCKN.js} +6 -135
- package/dist/twinHarness-KFZ2ZNAX.js +5 -0
- package/dist/{twinStart-E42H5CYD.js → twinStart-4OGP2GBY.js} +2 -2
- package/package.json +1 -1
- package/dist/src-JGOW5WYI.js +0 -5
- package/dist/src-KIHABGI5.js +0 -5
- package/dist/src-TUX5L2RC.js +0 -4
- package/dist/twinHarness-YTU4427G.js +0 -5
|
@@ -1,4 +1,9 @@
|
|
|
1
|
+
import './chunk-FKZZWWYC.js';
|
|
2
|
+
import { defaultSeedState, parseSeed } from './chunk-SGDUD7KK.js';
|
|
3
|
+
export { defaultSeedState, parseSeed, seedSchema } from './chunk-SGDUD7KK.js';
|
|
1
4
|
import { defineTwin, twinBuildInfo, UnknownToolError, openTwinDatabase, createApp } from './chunk-LZIPGCQJ.js';
|
|
5
|
+
import './chunk-VBATFCWR.js';
|
|
6
|
+
import './chunk-SG6ZTIMT.js';
|
|
2
7
|
import { z, ZodError } from 'zod';
|
|
3
8
|
import { createHash, randomUUID } from 'node:crypto';
|
|
4
9
|
|
|
@@ -453,7 +458,6 @@ var MUTATING_TOOL_NAMES = /* @__PURE__ */ new Set([
|
|
|
453
458
|
function isMutatingTool(name) {
|
|
454
459
|
return MUTATING_TOOL_NAMES.has(name);
|
|
455
460
|
}
|
|
456
|
-
var TAPE_ASSERTABLE_TOOLS = ["create_commit_status", "create_check_run"];
|
|
457
461
|
function executeTool(domain, name, input, onDelta, options = {}) {
|
|
458
462
|
const definition = toolDefinitions.find((tool) => tool.name === name);
|
|
459
463
|
if (!definition) {
|
|
@@ -1255,139 +1259,6 @@ function linesChanged(before, after) {
|
|
|
1255
1259
|
}
|
|
1256
1260
|
return { additions, deletions };
|
|
1257
1261
|
}
|
|
1258
|
-
var seedSchema = z.object({
|
|
1259
|
-
users: z.array(z.object({
|
|
1260
|
-
login: z.string().min(1),
|
|
1261
|
-
type: z.enum(["User", "Organization"]).default("User"),
|
|
1262
|
-
name: z.string().default("")
|
|
1263
|
-
})).default([]),
|
|
1264
|
-
repositories: z.array(z.object({
|
|
1265
|
-
owner: z.string().min(1),
|
|
1266
|
-
name: z.string().min(1),
|
|
1267
|
-
description: z.string().default(""),
|
|
1268
|
-
private: z.boolean().default(false),
|
|
1269
|
-
default_branch: z.string().min(1).default("main"),
|
|
1270
|
-
collaborators: z.array(z.string().min(1)).default([]),
|
|
1271
|
-
labels: z.array(z.object({
|
|
1272
|
-
name: z.string().min(1),
|
|
1273
|
-
color: z.string().default("ededed"),
|
|
1274
|
-
description: z.string().default("")
|
|
1275
|
-
})).default([]),
|
|
1276
|
-
files: z.array(z.object({ path: z.string().min(1), content: z.string(), branch: z.string().optional() })).default([]),
|
|
1277
|
-
issues: z.array(z.object({
|
|
1278
|
-
number: z.number().int().positive().optional(),
|
|
1279
|
-
title: z.string().min(1),
|
|
1280
|
-
body: z.string().default(""),
|
|
1281
|
-
state: z.enum(["open", "closed"]).default("open"),
|
|
1282
|
-
labels: z.array(z.string().min(1)).default([]),
|
|
1283
|
-
assignees: z.array(z.string().min(1)).default([])
|
|
1284
|
-
})).default([]),
|
|
1285
|
-
pull_requests: z.array(z.object({
|
|
1286
|
-
number: z.number().int().positive().optional(),
|
|
1287
|
-
title: z.string().min(1),
|
|
1288
|
-
body: z.string().default(""),
|
|
1289
|
-
head: z.string().min(1),
|
|
1290
|
-
base: z.string().min(1).default("main"),
|
|
1291
|
-
state: z.enum(["open", "closed"]).default("open"),
|
|
1292
|
-
author: z.string().min(1).optional(),
|
|
1293
|
-
// Reviews seeded on this PR. `state` mirrors GitHub's review
|
|
1294
|
-
// state enum; `author` must exist in the user/collaborator set.
|
|
1295
|
-
reviews: z.array(z.object({
|
|
1296
|
-
author: z.string().min(1),
|
|
1297
|
-
state: z.enum(["APPROVED", "CHANGES_REQUESTED", "COMMENTED"]).default("APPROVED"),
|
|
1298
|
-
body: z.string().default("")
|
|
1299
|
-
})).default([]),
|
|
1300
|
-
// Commit statuses applied to this PR's head SHA. Wired into the
|
|
1301
|
-
// commit_statuses table so get_pull_request_status and the merge
|
|
1302
|
-
// path see them without needing a separate setup call.
|
|
1303
|
-
statuses: z.array(z.object({
|
|
1304
|
-
context: z.string().min(1).default("ci/build"),
|
|
1305
|
-
state: z.enum(["error", "failure", "pending", "success"]).default("success"),
|
|
1306
|
-
description: z.string().default("")
|
|
1307
|
-
})).default([])
|
|
1308
|
-
})).default([])
|
|
1309
|
-
}))
|
|
1310
|
-
});
|
|
1311
|
-
function parseSeed(input) {
|
|
1312
|
-
const seed = seedSchema.parse(normalizeLegacyGitHubSeed(input));
|
|
1313
|
-
if (seed.repositories.length === 0) {
|
|
1314
|
-
throw new Error("GitHub seed must contain at least one repository");
|
|
1315
|
-
}
|
|
1316
|
-
return seed;
|
|
1317
|
-
}
|
|
1318
|
-
function normalizeLegacyGitHubSeed(input) {
|
|
1319
|
-
if (!input || typeof input !== "object" || Array.isArray(input))
|
|
1320
|
-
return input;
|
|
1321
|
-
const seed = input;
|
|
1322
|
-
if (!Array.isArray(seed.repositories))
|
|
1323
|
-
return input;
|
|
1324
|
-
return {
|
|
1325
|
-
...seed,
|
|
1326
|
-
repositories: seed.repositories.map((repo) => {
|
|
1327
|
-
if (!repo || typeof repo !== "object" || Array.isArray(repo))
|
|
1328
|
-
return repo;
|
|
1329
|
-
const record = repo;
|
|
1330
|
-
if (!Array.isArray(record.issues))
|
|
1331
|
-
return repo;
|
|
1332
|
-
return {
|
|
1333
|
-
...record,
|
|
1334
|
-
issues: record.issues.map((issue) => normalizeLegacyIssueAssignee(issue))
|
|
1335
|
-
};
|
|
1336
|
-
})
|
|
1337
|
-
};
|
|
1338
|
-
}
|
|
1339
|
-
function normalizeLegacyIssueAssignee(issue) {
|
|
1340
|
-
if (!issue || typeof issue !== "object" || Array.isArray(issue))
|
|
1341
|
-
return issue;
|
|
1342
|
-
const record = issue;
|
|
1343
|
-
if (!("assignee" in record) || "assignees" in record)
|
|
1344
|
-
return issue;
|
|
1345
|
-
const { assignee, ...rest } = record;
|
|
1346
|
-
if (assignee === null || assignee === void 0 || assignee === "") {
|
|
1347
|
-
return { ...rest, assignees: [] };
|
|
1348
|
-
}
|
|
1349
|
-
if (typeof assignee === "string") {
|
|
1350
|
-
return { ...rest, assignees: [assignee] };
|
|
1351
|
-
}
|
|
1352
|
-
return issue;
|
|
1353
|
-
}
|
|
1354
|
-
function defaultSeedState() {
|
|
1355
|
-
return {
|
|
1356
|
-
users: [
|
|
1357
|
-
{ login: "acme", type: "Organization", name: "Acme" },
|
|
1358
|
-
{ login: "alice", type: "User", name: "Alice" },
|
|
1359
|
-
{ login: "bob", type: "User", name: "Bob" },
|
|
1360
|
-
{ login: "pome-agent", type: "User", name: "Pome Agent" }
|
|
1361
|
-
],
|
|
1362
|
-
repositories: [
|
|
1363
|
-
{
|
|
1364
|
-
owner: "acme",
|
|
1365
|
-
name: "api",
|
|
1366
|
-
description: "Example API service used by GitHub twin tests.",
|
|
1367
|
-
default_branch: "main",
|
|
1368
|
-
collaborators: ["alice", "bob", "pome-agent"],
|
|
1369
|
-
labels: [
|
|
1370
|
-
{ name: "bug", color: "d73a4a", description: "Something is not working" },
|
|
1371
|
-
{ name: "feature", color: "a2eeef", description: "New feature or request" },
|
|
1372
|
-
{ name: "question", color: "d876e3", description: "More information needed" }
|
|
1373
|
-
],
|
|
1374
|
-
files: [
|
|
1375
|
-
{ path: "README.md", content: "# Acme API\n\nA seeded repository for local GitHub twin tests.\n" },
|
|
1376
|
-
{ path: "src/index.ts", content: "export function handler() {\n return 'ok';\n}\n" }
|
|
1377
|
-
],
|
|
1378
|
-
issues: [
|
|
1379
|
-
{
|
|
1380
|
-
number: 1,
|
|
1381
|
-
title: "500 error on POST /orders after deploy",
|
|
1382
|
-
body: "Started failing right after the 14:00 deploy. Stack trace points to OrderController#create.",
|
|
1383
|
-
labels: ["bug"],
|
|
1384
|
-
assignees: []
|
|
1385
|
-
}
|
|
1386
|
-
]
|
|
1387
|
-
}
|
|
1388
|
-
]
|
|
1389
|
-
};
|
|
1390
|
-
}
|
|
1391
1262
|
|
|
1392
1263
|
// ../packages/twin-github/dist/src/serializers.js
|
|
1393
1264
|
function repoState(repo) {
|
|
@@ -4387,4 +4258,4 @@ function createGitHubCloneApp(options = {}) {
|
|
|
4387
4258
|
});
|
|
4388
4259
|
}
|
|
4389
4260
|
|
|
4390
|
-
export { GitHubDomain,
|
|
4261
|
+
export { GitHubDomain, createGitHubCloneApp, executeTool, githubTwinDefinition, listTools, openGitHubCloneDatabase, resetDatabase, toolDefinitions };
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { bootTwin } from './chunk-
|
|
2
|
-
import { isTwinName, TWIN_NAMES, defaultPortFor, TWIN_REGISTRY } from './chunk-
|
|
1
|
+
import { bootTwin } from './chunk-M3X6OT4N.js';
|
|
2
|
+
import { isTwinName, TWIN_NAMES, defaultPortFor, TWIN_REGISTRY } from './chunk-A3IDZXJY.js';
|
|
3
3
|
import './chunk-LZIPGCQJ.js';
|
|
4
4
|
import './chunk-VBATFCWR.js';
|
|
5
5
|
import './chunk-SG6ZTIMT.js';
|
package/package.json
CHANGED
package/dist/src-JGOW5WYI.js
DELETED
|
@@ -1,5 +0,0 @@
|
|
|
1
|
-
export { DEFAULT_LINEAR_CLOCK, DEFAULT_LINEAR_EMAIL, DEFAULT_LINEAR_PORT, DEFAULT_LINEAR_SID, DEFAULT_LINEAR_TOKEN, LINEAR_CHECKS, LINEAR_MCP_TOOL_COUNT, LINEAR_PROVIDER_TOKEN_PREFIX, LinearDomain, LinearTwinError, STATE_EXPORT_CAP, assertWebhookUrl, createLinearTwinApp, createLinearTwinDefinition, defaultSeedState, exportLinearState, linearErrorEnvelope, linearSeedSchema, linearStateDelta, linearTools, loadSeedFromEnv, looksLikeLinearToken, migrate, openLinearTwinDatabase, parseSeed, projectLinearRecording, registerLinearRoutes, resetDatabase, resolveLinearCredential, unauthorizedEnvelope, unsupportedEnvelope, webhookUrlError, withPublicOAuth } from './chunk-APAS34RJ.js';
|
|
2
|
-
import './chunk-NY55QTVQ.js';
|
|
3
|
-
import './chunk-LZIPGCQJ.js';
|
|
4
|
-
import './chunk-VBATFCWR.js';
|
|
5
|
-
import './chunk-SG6ZTIMT.js';
|
package/dist/src-KIHABGI5.js
DELETED
|
@@ -1,5 +0,0 @@
|
|
|
1
|
-
export { DEFAULT_GMAIL_AGENT_EMAIL, DEFAULT_GMAIL_EMAIL, GMAIL_CHECKS, GmailDomain, GmailError, SEARCH_MAILBOX_MESSAGE_BUDGET, STATE_EXPORT_COLLECTION_CAP, STATE_EXPORT_FULL_MESSAGE_BUDGET, agentPathInboxMailbox, canonicalRaw, capExportRows, composeMime, createGmailTwinApp, decodeGmailRaw, defaultSeedState, encodeGmailRaw, exportGmailState, gmailErrorEnvelope, gmailSeedSchema, gmailStateDelta, gmailTools, gmailTwinDefinition, identityFromSession, loadSeedFromEnv, matchesSearch, migrate, mimeSha256, normalizeSubject, openGmailTwinDatabase, parseMime, parseSearchQuery, parseSeed, projectGmailRecording, registerGmailRoutes, resetDatabase, resolveUserEmail, stripBcc, stripHtmlTags, validateSearchQuery } from './chunk-WVWV7DLA.js';
|
|
2
|
-
import './chunk-NY55QTVQ.js';
|
|
3
|
-
import './chunk-LZIPGCQJ.js';
|
|
4
|
-
import './chunk-VBATFCWR.js';
|
|
5
|
-
import './chunk-SG6ZTIMT.js';
|
package/dist/src-TUX5L2RC.js
DELETED
|
@@ -1,4 +0,0 @@
|
|
|
1
|
-
export { GitHubDomain, createGitHubCloneApp, defaultSeedState, executeTool, githubTwinDefinition, listTools, openGitHubCloneDatabase, parseSeed, resetDatabase, seedSchema, toolDefinitions } from './chunk-OKDJRKJV.js';
|
|
2
|
-
import './chunk-LZIPGCQJ.js';
|
|
3
|
-
import './chunk-VBATFCWR.js';
|
|
4
|
-
import './chunk-SG6ZTIMT.js';
|