Skip to content

abso-core

Public

abso is version control for agents: the client, the engine and a server you can run on your own Cloudflare account.

Check passed

Versions 99 to 100

Compare

+36 −42 in 22 places
Lines 73–79 at 100 (were 73–79 at 99)
7373 const rawWait = str(args, "wait");
7474 if (rawWait !== undefined && !/^\d{1,4}$/.test(rawWait))
7575 throw new UsageError(
76− `--wait is how many seconds to wait for a queued publish to land, like 100 (got ${JSON.stringify(rawWait)})`,
76+ `--wait is how many seconds to wait for a queued push to land, like 100 (got ${JSON.stringify(rawWait)})`,
7777 );
7878 const waitSeconds = bool(args, "no-wait") ? 0 : rawWait === undefined ? WAIT_SECONDS : Number(rawWait);
7979 let skippedCheck = false;
Lines 105–127 at 100 (were 105–127 at 99)
105105 const say = env.writeErr ?? env.write;
106106 // Known to have no prep: refuse before syncing and running (#37). Unknown: the run below tells.
107107 const noPrep =
108− "your box has no prep, so a check would run without node_modules and its result couldn't be trusted. Run abso prep 'npm ci --ignore-scripts' once (every fresh box then starts from it), then publish --check again.";
108+ "your box has no prep, so a check would run without node_modules and its result couldn't be trusted. Run abso prep 'npm ci --ignore-scripts' once (every fresh box then starts from it), then push --check again.";
109109 if (knownPrep(root, boxOf(args, env)) === null && existsSync(join(root, "package-lock.json"))) {
110110 return {
111111 exit: EXIT.refused,
112− text: `Not published: ${noPrep} (Nothing was run: this folder's last run in that box said it had no prep.)`,
112+ text: `Not pushed: ${noPrep} (Nothing was run: this folder's last run in that box said it had no prep.)`,
113113 json: { check: { command: check, ran: false, prep: null } },
114114 };
115115 }
116116 const synced = await unreached(
117117 runSync({ positionals: [], flags: new Map() }, env),
118− "Nothing was published, and the check didn't run.",
118+ "Nothing was pushed, and the check didn't run.",
119119 );
120120 const sj = synced.json as { collisions?: readonly unknown[]; refused?: readonly Refused[] };
121121 if ((sj.collisions?.length ?? 0) > 0) {
122122 return {
123123 exit: EXIT.refused,
124− text: `${synced.text}\nNot published: the sync before the check left collisions. Settle them, then publish --check again.`,
124+ text: `${synced.text}\nNot pushed: the pull before the check left collisions. Settle them, then push --check again.`,
125125 json: { check: null, sync: synced.json },
126126 };
127127 }
Lines 129–135 at 100 (were 129–135 at 99)
129129 // Paths the sync wouldn't write (safety.ts) don't block: the check just ran without them.
130130 if ((sj.refused?.length ?? 0) > 0)
131131 say(
132− `abso: the sync didn't write these: ${sj.refused!.map((r) => r.path).join(", ")}; the check runs without them.\n`,
132+ `abso: the pull didn't write these: ${sj.refused!.map((r) => r.path).join(", ")}; the check runs without them.\n`,
133133 );
134134 say(`abso: checking your draft on newest shared in the box: ${check}\n`);
135135 const flags = new Map<string, string | boolean>();
Lines 141–147 at 100 (were 141–147 at 99)
141141 if ((ran.json as { prep?: string | null }).prep === null && existsSync(join(root, "package-lock.json"))) {
142142 return {
143143 exit: EXIT.refused,
144− text: "Not published: your box has no prep, so the check ran without node_modules and its result can't be trusted. Run abso prep 'npm ci --ignore-scripts' once (every fresh box then starts from it), then publish --check again.",
144+ text: "Not pushed: your box has no prep, so the check ran without node_modules and its result can't be trusted. Run abso prep 'npm ci --ignore-scripts' once (every fresh box then starts from it), then push --check again.",
145145 json: { check: { command: check, exit: ran.exit ?? 0, prep: null } },
146146 };
147147 }
Lines 175–181 at 100 (were 175–181 at 99)
175175 return {
176176 exit: EXIT.refused,
177177 text: [
178− `Not published: the check failed (exit ${ran.exit}) on your draft with newest shared. Its output is above.`,
178+ `Not pushed: the check failed (exit ${ran.exit}) on your draft with newest shared. Its output is above.`,
179179 ...verdict,
180180 ].join("\n"),
181181 json: {
Lines 187–193 at 100 (were 187–193 at 99)
187187 },
188188 };
189189 }
190− say("abso: the check passed; publishing.\n");
190+ say("abso: the check passed; pushing.\n");
191191 }
192192 const checked = check !== undefined;
193193 const leftOut: LeftOut[] = [];
Lines 195–202 at 100 (were 195–204 at 99)
195195 // Say how far it got when the server can't be reached (#37, GAME - UI/UX: did the check run? did the draft go up?).
196196 const reached = await unreached(
197197 steps,
198− checked
199− ? "The check passed, but the publish never reached the server: nothing was published."
200− : "Nothing was published.",
201− `${checked ? "The check passed; " : ""}the publish may have reached the server before its answer was lost: abso status shows whether your draft was published.`,
198+ checked ? "The check passed, but the push never reached the server: nothing was pushed." : "Nothing was pushed.",
199+ `${checked ? "The check passed; " : ""}the push may have reached the server before its answer was lost: abso status shows whether your draft was pushed.`,
202200 );
203201 const out = withLeftOut(reached, leftOut);
204202 // --done: this publish finishes the work the start note named (#44): take the note back once it's published.
Lines 207–213 at 100 (were 209–215 at 99)
209207 if (queued === undefined || outcome === "pulled") return out;
210208 return {
211209 ...out,
212− text: `${out.text}\nYour start note stays (--done): publish ${queued} hasn't landed yet. Once it has, abso start --done takes the note back and abso issue <N> --done closes the issue it names.`,
210+ text: `${out.text}\nYour start note stays (--done): push ${queued} hasn't landed yet. Once it has, abso start --done takes the note back and abso issue <N> --done closes the issue it names.`,
213211 };
214212 }
215213 // done (#54): the work is finished, so an issue the note named is closed with this change.
Lines 242–248 at 100 (were 244–250 at 99)
244242 );
245243 if (landed) {
246244 return {
247− text: `Published version ${landed.version}. The server's answer was lost (${why}), but shared's log shows your publish landed.`,
245+ text: `Pushed version ${landed.version}. The server's answer was lost (${why}), but shared's log shows your push landed.`,
248246 json: { version: landed.version, lostAnswer: why },
249247 };
250248 }
Lines 252–264 at 100 (were 254–266 at 99)
254252 if (queued) {
255253 return {
256254 exit: STILL_QUEUED,
257− text: `Queued as publish ${queued.id}. The server's answer was lost (${why}), but the merge queue holds your publish; the outcome comes as news on your next edit, and abso status shows the queue.`,
255+ text: `Queued as push ${queued.id}. The server's answer was lost (${why}), but the merge queue holds your push; the outcome comes as news on your next edit, and abso status shows the queue.`,
258256 json: { queued: queued.id, outcome: "queued", lostAnswer: why },
259257 };
260258 }
261259 return {
262260 exit: EXIT.error,
263− text: `Not published: ${why}. Shared's newest versions and the merge queue don't have it, so it's safe to publish again.`,
261+ text: `Not pushed: ${why}. Shared's newest versions and the merge queue don't have it, so it's safe to push again.`,
264262 json: { published: false, lostAnswer: why },
265263 };
266264 } catch {
Lines 301–307 at 100 (were 303–309 at 99)
303301 // Publishing now would leave the others on the file's old text without anyone noticing (#25).
304302 return {
305303 exit: EXIT.refused,
306− text: [...pre, ...turnedBinaryText(recorded.turnedBinary), "Not published."].join("\n"),
304+ text: [...pre, ...turnedBinaryText(recorded.turnedBinary), "Not pushed."].join("\n"),
307305 json: { turnedBinary: recorded.turnedBinary, recorded: recorded.sent },
308306 };
309307 }
Lines 329–335 at 100 (were 331–337 at 99)
331329 if (answer.ok && "queued" in answer) {
332330 // The merge queue (#39): it lands once a batch with it passes the project's check.
333331 const say = env.writeErr ?? env.write;
334− const head = `Queued as publish ${answer.queued}${answer.ahead === 0 ? "" : `, ${answer.ahead} ${answer.ahead === 1 ? "publish" : "publishes"} ahead of it`}: it lands once the project's check passes on it in the merge queue.`;
332+ const head = `Queued as push ${answer.queued}${answer.ahead === 0 ? "" : `, ${answer.ahead} ${answer.ahead === 1 ? "push" : "pushes"} ahead of it`}: it lands once the project's check passes on it in the merge queue.`;
335333 const notes = [
336334 ...pre,
337335 ...(skippedCheck
Lines 363–369 at 100 (were 365–373 at 99)
365363 if (out.kind !== "waiting") heard(root, out.news);
366364 if (out.kind === "landed")
367365 return {
368− text: [...notes, `Published version ${out.version}: it passed the project's check in the merge queue.`].join(
369− "\n",
370− ),
366+ text: [...notes, `Pushed version ${out.version}: it passed the project's check in the merge queue.`].join("\n"),
371367 json: { ...json, version: out.version, outcome: "landed" },
372368 };
373369 if (out.kind === "pulled")
Lines 377–383 at 100 (were 381–387 at 99)
381377 exit: STILL_QUEUED,
382378 text: [
383379 ...notes,
384− `Publish ${answer.queued} left the merge queue, but nothing said whether it landed: abso log -n 3 shows it if it did.`,
380+ `Push ${answer.queued} left the merge queue, but nothing said whether it landed: abso log -n 3 shows it if it did.`,
385381 ].join("\n"),
386382 json: { ...json, outcome: "unknown" },
387383 };
Lines 387–393 at 100 (were 391–399 at 99)
391387 : "still in the queue (the queue could not be read)";
392388 return {
393389 exit: STILL_QUEUED,
394− text: [...notes, `Still queued after ${waitSeconds} s: publish ${answer.queued} is ${where}. ${later}`].join(
395− "\n",
396− ),
390+ text: [...notes, `Still queued after ${waitSeconds} s: push ${answer.queued} is ${where}. ${later}`].join("\n"),
397391 json: { ...json, outcome: "queued" },
398392 };
399393 }
Lines 396–402 at 100 (were 402–408 at 99)
402396 const what =
403397 answer.changes === 0
404398 ? await alreadyInShared(root, api, config.agent, recorded.paths, answer.version)
405− : `Published version ${answer.version}.${merged.length > 0 ? ` ${mergedText(merged)}` : ""}`;
399+ : `Pushed version ${answer.version}.${merged.length > 0 ? ` ${mergedText(merged)}` : ""}`;
406400 // The check ran on shared as it was; what landed since went in unchecked.
407401 const moved =
408402 checked && merged.length > 0
Lines 434–442 at 100 (were 440–448 at 99)
440434 exit: EXIT.refused,
441435 text: [
442436 ...pre,
443− `Not published: ${files.join(", ")} still ${files.length === 1 ? "has" : "have"} collision markers (${plural(collisions.length, "block")}).`,
437+ `Not pushed: ${files.join(", ")} still ${files.length === 1 ? "has" : "have"} collision markers (${plural(collisions.length, "block")}).`,
444438 ...collisions.map(collisionText),
445− `Settle each: keep yours, theirs or a mix and delete the marker lines, or abso settle <file> --yours|--theirs|--both. Then publish again. abso publish --as-is keeps both sides everywhere; the other authors hear it.`,
439+ `Settle each: keep yours, theirs or a mix and delete the marker lines, or abso settle <file> --yours|--theirs|--both. Then push again. abso push --as-is keeps both sides everywhere; the other authors hear it.`,
446440 ].join("\n"),
447441 json: { collisions, recorded: recorded.sent },
448442 };
Lines 447–455 at 100 (were 453–461 at 99)
453447 exit: EXIT.refused,
454448 text: [
455449 ...pre,
456− `Not published: ${plural(collisions.length, "collision")} you synced into and haven't edited since. Both sides' lines are still in the file, so publishing now would put them in shared twice.`,
450+ `Not pushed: ${plural(collisions.length, "collision")} you pulled into and haven't edited since. Both sides' lines are still in the file, so pushing now would put them in shared twice.`,
457451 ...collisions.map(collisionText),
458− "Edit each to what it should be (keep yours, theirs, or a mix), then publish again. If both really belong, abso publish --as-is keeps both.",
452+ "Edit each to what it should be (keep yours, theirs, or a mix), then push again. If both really belong, abso push --as-is keeps both.",
459453 ].join("\n"),
460454 json: { collisions, recorded: recorded.sent },
461455 };
Lines 463–485 at 100 (were 469–491 at 99)
469463 text: [
470464 ...pre,
471465 // A name defined twice is already in your folder (sync listed it); the rest is newer work.
472− `Not published: ${plural(collisions.length, "collision")}${newer.length > 0 ? " with work published since your last sync" : ""}.${answer.reason ? ` (${answer.reason})` : ""}`,
466+ `Not pushed: ${plural(collisions.length, "collision")}${newer.length > 0 ? " with work pushed since your last pull" : ""}.${answer.reason ? ` (${answer.reason})` : ""}`,
473467 ...real.map(collisionText),
474468 ...(local.length > 0
475469 ? [
476− ` ${local.map((c) => c.file).join(", ")}: local files that should never have been shared. abso sync drops them from your draft and leaves your copy on disk.`,
470+ ` ${local.map((c) => c.file).join(", ")}: local files that should never have been shared. abso pull drops them from your draft and leaves your copy on disk.`,
477471 ]
478472 : []),
479473 ...(real.some((c) => c.theirs.queued !== undefined)
480474 ? [
481− "Some of theirs are still in the merge queue, not in shared: once they land (abso status shows the queue), abso sync brings them in to settle; if they're pulled, publish again as you are.",
475+ "Some of theirs are still in the merge queue, not in shared: once they land (abso status shows the queue), abso pull brings them in to settle; if they're turned back, push again as you are.",
482476 ]
483477 : []),
484478 newer.length > 0
485− ? `Run abso sync: each of those files comes back holding both sides' lines, with no markers. Edit it to what it should be${twice.length > 0 ? ", keep one definition of each name defined twice" : ""}, then publish again.`
479+ ? `Run abso pull: each of those files comes back holding both sides' lines, with no markers. Edit it to what it should be${twice.length > 0 ? ", keep one definition of each name defined twice" : ""}, then push again.`
486480 : twice.length > 0
487− ? "Keep one definition of each name defined twice (delete yours, or theirs), then publish again."
488− : "Run abso sync, then publish again.",
481+ ? "Keep one definition of each name defined twice (delete yours, or theirs), then push again."
482+ : "Run abso pull, then push again.",
489483 ].join("\n"),
490484 json: { collisions, recorded: recorded.sent, ...(answer.reason ? { reason: answer.reason } : {}) },
491485 };
Lines 498–511 at 100 (were 504–517 at 99)
504498 ...turnedBinaryText(recorded.turnedBinary),
505499 ...recordedFirst(recorded),
506500 ...droppedIgnoredText(ignoredDropped),
507− `Synced to version ${s.version}: ${changes === 0 ? "no files changed" : `${plural(updated.length, "file")} updated, ${removed.length} deleted${s.renamed.length > 0 ? `, ${s.renamed.length} renamed` : ""}`}.`,
508− ...changedFilesText("sync", updated, removed, s.renamed, bool(args, "verbose")),
501+ `Pulled to version ${s.version}: ${changes === 0 ? "no files changed" : `${plural(updated.length, "file")} updated, ${removed.length} deleted${s.renamed.length > 0 ? `, ${s.renamed.length} renamed` : ""}`}.`,
502+ ...changedFilesText("pull", updated, removed, s.renamed, bool(args, "verbose")),
509503 ...refusedText(s.refused),
510504 // Ones an earlier sync couldn't write; this sync's are named just above.
511505 ...unwrittenText(s.unwritten, new Set(s.refused.map((r) => r.path))),
512506 ...mergedLinesText(s.merged),
513507 ...(s.kept.length > 0
514− ? [`Left alone because they changed while syncing (run abso sync again): ${s.kept.join(", ")}`]
508+ ? [`Left alone because they changed while pulling (run abso pull again): ${s.kept.join(", ")}`]
515509 : []),
516510 ...(s.dropped.length > 0
517511 ? [`Dropped from your draft, kept on disk (these stay local): ${s.dropped.join(", ")}`]
Lines 563–569 at 100 (were 569–575 at 99)
569563 recordedPaths: readonly string[],
570564 version: number,
571565): Promise<string> {
572− const empty = `Nothing to publish: your draft is empty. Shared is at version ${version}.`;
566+ const empty = `Nothing to push: your draft is empty. Shared is at version ${version}.`;
573567 const log = await api.log({ agent }, FOLDER_LOG_LIMIT);
574568 const since = log.versions.find((v) => v.agent === agent)?.time ?? 0;
575569 const edited = new Set(recordedPaths);
Lines 582–588 at 100 (were 588–594 at 99)
588582 found.push(`${rel} (version ${last.version}, ${last.agent}: "${last.message}")`);
589583 }
590584 if (found.length === 0) return empty;
591− return `Nothing published: shared already has ${found.length === 1 ? "the file you changed" : "the files you changed"} as you have ${found.length === 1 ? "it" : "them"}, so nothing of yours is lost. Last changed in ${found.join("; ")}. Shared is at version ${version}.`;
585+ return `Nothing pushed: shared already has ${found.length === 1 ? "the file you changed" : "the files you changed"} as you have ${found.length === 1 ? "it" : "them"}, so nothing of yours is lost. Last changed in ${found.join("; ")}. Shared is at version ${version}.`;
592586}
593587
594588/**
MCP
compare on this site's /mcp
CLI
abso diff 99 100 client/src/publish-commands.ts --json
JSON
/christopher/abso-core/compare/99..100?file=client%2Fsrc%2Fpublish-commands.ts&format=json