@staff0rd/assist 0.576.0 → 0.577.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/dist/index.js CHANGED
@@ -6,7 +6,7 @@ import { Command } from "commander";
6
6
  // package.json
7
7
  var package_default = {
8
8
  name: "@staff0rd/assist",
9
- version: "0.576.0",
9
+ version: "0.577.0",
10
10
  type: "module",
11
11
  main: "dist/index.js",
12
12
  bin: {
@@ -14914,12 +14914,12 @@ async function link(fromId, toId, opts) {
14914
14914
  const { orm } = await getReady();
14915
14915
  const fromItem = await loadItem(orm, fromNum);
14916
14916
  if (!fromItem) return void fail4(`Item ${from} not found.`);
14917
- const toItem = await loadItem(orm, toNum);
14918
- if (!toItem) return void fail4(`Item ${to} not found.`);
14917
+ const toItem2 = await loadItem(orm, toNum);
14918
+ if (!toItem2) return void fail4(`Item ${to} not found.`);
14919
14919
  if (!validateLinkTarget(fromItem, fromNum, toNum, linkType)) return;
14920
14920
  if (await createsCycle(orm, linkType, fromNum, toNum)) return;
14921
14921
  await orm.insert(links).values({ itemId: fromNum, type: linkType, targetId: toNum });
14922
- console.log(chalk85.green(`Linked ${from} ${linkType} ${to} (${toItem.name})`));
14922
+ console.log(chalk85.green(`Linked ${from} ${linkType} ${to} (${toItem2.name})`));
14923
14923
  }
14924
14924
 
14925
14925
  // src/commands/backlog/unlink.ts
@@ -22727,6 +22727,186 @@ function registerMermaid(program2) {
22727
22727
  configHelp(cmd, mermaidConfigHelp);
22728
22728
  }
22729
22729
 
22730
+ // src/commands/miro/runExtract.ts
22731
+ import { stringify } from "yaml";
22732
+
22733
+ // src/commands/miro/MiroExtractError.ts
22734
+ var MiroExtractError = class extends Error {
22735
+ constructor(message3) {
22736
+ super(message3);
22737
+ this.name = "MiroExtractError";
22738
+ }
22739
+ };
22740
+
22741
+ // src/commands/miro/stripHtml.ts
22742
+ var namedEntities = {
22743
+ amp: "&",
22744
+ apos: "'",
22745
+ gt: ">",
22746
+ lt: "<",
22747
+ nbsp: " ",
22748
+ quot: '"'
22749
+ };
22750
+ function decodeEntity(_match, entity) {
22751
+ if (entity.startsWith("#")) {
22752
+ const code = entity.startsWith("#x") || entity.startsWith("#X") ? Number.parseInt(entity.slice(2), 16) : Number.parseInt(entity.slice(1), 10);
22753
+ return Number.isNaN(code) ? _match : String.fromCodePoint(code);
22754
+ }
22755
+ return namedEntities[entity.toLowerCase()] ?? _match;
22756
+ }
22757
+ function stripHtml2(content) {
22758
+ return content.replace(/<br\s*\/?>/gi, " ").replace(/<\/(?:p|div|li|h[1-6])>/gi, " ").replace(/<[^>]*>/g, "").replace(/&(#[0-9a-f]+|[a-z]+);/gi, decodeEntity).replace(/\s+/g, " ").trim();
22759
+ }
22760
+
22761
+ // src/commands/miro/normaliseItems.ts
22762
+ var frameCoordinates = "parent_top_left";
22763
+ function describe2(item) {
22764
+ return ` ${item.id ?? "(no id)"} (${item.type ?? "unknown type"}): relativeTo=${item.position?.relativeTo ?? "missing"}`;
22765
+ }
22766
+ function coordinateSpaceError(rejected) {
22767
+ return new MiroExtractError(
22768
+ `${rejected.length} item(s) are not in frame coordinates (position.relativeTo must be "${frameCoordinates}"):
22769
+ ${rejected.slice(0, 5).map(describe2).join(
22770
+ "\n"
22771
+ )}
22772
+
22773
+ Dump the frame with board_list_items using ?moveToWidget=<frame id> so every item shares one coordinate space.`
22774
+ );
22775
+ }
22776
+ function toItem(item) {
22777
+ const halfWidth = (item.geometry?.width ?? 0) / 2;
22778
+ const halfHeight = (item.geometry?.height ?? 0) / 2;
22779
+ const x = item.position?.x ?? 0;
22780
+ const y = item.position?.y ?? 0;
22781
+ return {
22782
+ id: item.id ?? "",
22783
+ type: item.type ?? "",
22784
+ text: stripHtml2(item.data?.content ?? ""),
22785
+ left: x - halfWidth,
22786
+ top: y - halfHeight,
22787
+ right: x + halfWidth,
22788
+ bottom: y + halfHeight
22789
+ };
22790
+ }
22791
+ function normaliseItems(items2) {
22792
+ const rejected = items2.filter(
22793
+ (item) => item.position?.relativeTo !== frameCoordinates
22794
+ );
22795
+ if (rejected.length > 0) throw coordinateSpaceError(rejected);
22796
+ return items2.map(toItem);
22797
+ }
22798
+
22799
+ // src/commands/miro/parseAnchorId.ts
22800
+ function parseAnchorId(value) {
22801
+ const trimmed = value.trim();
22802
+ const link3 = /[?&]moveToWidget=([^&#]+)/.exec(trimmed);
22803
+ return link3 ? decodeURIComponent(link3[1]).trim() : trimmed;
22804
+ }
22805
+
22806
+ // src/commands/miro/readMiroItems.ts
22807
+ import { readFileSync as readFileSync40 } from "fs";
22808
+ function tryParse(text18) {
22809
+ try {
22810
+ return JSON.parse(text18);
22811
+ } catch {
22812
+ return void 0;
22813
+ }
22814
+ }
22815
+ function toPage(value) {
22816
+ const record = value ?? {};
22817
+ if (Array.isArray(record.data)) return { data: record.data };
22818
+ return record.id ? { data: [record] } : {};
22819
+ }
22820
+ function parseJsonLines(raw, file) {
22821
+ return raw.split("\n").map((line) => line.trim()).filter(Boolean).map((line) => {
22822
+ const parsed = tryParse(line);
22823
+ if (parsed === void 0)
22824
+ throw new MiroExtractError(
22825
+ `${file} is not valid JSON or JSON lines. Save the raw board_list_items response pages without editing them.`
22826
+ );
22827
+ return toPage(parsed);
22828
+ });
22829
+ }
22830
+ function parsePages(raw, file) {
22831
+ const parsed = tryParse(raw);
22832
+ if (parsed === void 0) return parseJsonLines(raw, file);
22833
+ return Array.isArray(parsed) ? parsed.map(toPage) : [toPage(parsed)];
22834
+ }
22835
+ function readMiroItems(file) {
22836
+ const items2 = parsePages(readFileSync40(file, "utf8"), file).flatMap(
22837
+ (page) => page.data ?? []
22838
+ );
22839
+ if (items2.length === 0)
22840
+ throw new MiroExtractError(
22841
+ `No board items found in ${file}. Dump the frame with board_list_items, paging until has_more is false.`
22842
+ );
22843
+ return items2;
22844
+ }
22845
+
22846
+ // src/commands/miro/selectBoxes.ts
22847
+ var boxTypes = /* @__PURE__ */ new Set(["shape", "sticky_note"]);
22848
+ function findAnchor(items2, id) {
22849
+ const anchor = items2.find((item) => item.id === id);
22850
+ if (!anchor)
22851
+ throw new MiroExtractError(
22852
+ `No item with id ${id} in the supplied items. Re-dump the frame so the anchor is included, then try again.`
22853
+ );
22854
+ return anchor;
22855
+ }
22856
+ function isBox(item) {
22857
+ return boxTypes.has(item.type) && item.text.length > 0;
22858
+ }
22859
+ function centreInside(rect, item) {
22860
+ const x = (item.left + item.right) / 2;
22861
+ const y = (item.top + item.bottom) / 2;
22862
+ return x >= rect.left && x <= rect.right && y >= rect.top && y <= rect.bottom;
22863
+ }
22864
+ function selectBoxes(items2, topLeftId, bottomRightId) {
22865
+ const topLeft = findAnchor(items2, topLeftId);
22866
+ const bottomRight = findAnchor(items2, bottomRightId);
22867
+ const rect = {
22868
+ left: topLeft.left,
22869
+ top: topLeft.top,
22870
+ right: bottomRight.right,
22871
+ bottom: bottomRight.bottom
22872
+ };
22873
+ return items2.filter((item) => isBox(item) && centreInside(rect, item)).sort((a, b) => a.left - b.left || a.top - b.top);
22874
+ }
22875
+
22876
+ // src/commands/miro/runExtract.ts
22877
+ function requireItems(file) {
22878
+ if (!file)
22879
+ throw new MiroExtractError(
22880
+ "--items <file> is required: a file of raw board_list_items response pages."
22881
+ );
22882
+ return file;
22883
+ }
22884
+ function requireAnchors(options2) {
22885
+ if (!options2.topLeft || !options2.bottomRight)
22886
+ throw new MiroExtractError(
22887
+ "Both --top-left <id|link> and --bottom-right <id|link> are required."
22888
+ );
22889
+ return [parseAnchorId(options2.topLeft), parseAnchorId(options2.bottomRight)];
22890
+ }
22891
+ function runExtract(options2) {
22892
+ const [topLeft, bottomRight] = requireAnchors(options2);
22893
+ const items2 = normaliseItems(readMiroItems(requireItems(options2.items)));
22894
+ const boxes = selectBoxes(items2, topLeft, bottomRight);
22895
+ process.stdout.write(stringify(boxes.map((box) => box.text)));
22896
+ }
22897
+
22898
+ // src/commands/miro/registerMiro.ts
22899
+ function registerMiro(program2) {
22900
+ const miroCommand = program2.command("miro").description("Miro board utilities");
22901
+ miroCommand.command("extract").description("Print the text of every box inside a rectangle on a board").option("--items <file>", "File of raw board_list_items response pages").option(
22902
+ "--top-left <id>",
22903
+ "Widget id or ?moveToWidget=<id> link of the top-left box"
22904
+ ).option(
22905
+ "--bottom-right <id>",
22906
+ "Widget id or ?moveToWidget=<id> link of the bottom-right box"
22907
+ ).action(runExtract);
22908
+ }
22909
+
22730
22910
  // src/commands/netcap/netcap.ts
22731
22911
  import { mkdir as mkdir4 } from "fs/promises";
22732
22912
  import { createServer as createServer2 } from "http";
@@ -22936,7 +23116,7 @@ import { join as join61 } from "path";
22936
23116
  import chalk171 from "chalk";
22937
23117
 
22938
23118
  // src/commands/netcap/extractPostsFromCapture.ts
22939
- import { readFileSync as readFileSync40 } from "fs";
23119
+ import { readFileSync as readFileSync41 } from "fs";
22940
23120
 
22941
23121
  // src/commands/netcap/parseRscRows.ts
22942
23122
  var isRscRef = (v) => typeof v === "string" && /^\$[0-9a-fL@]/.test(v);
@@ -23332,7 +23512,7 @@ function extractVoyagerPosts(body) {
23332
23512
 
23333
23513
  // src/commands/netcap/extractPostsFromCapture.ts
23334
23514
  function captureEntries(captureFile) {
23335
- const lines2 = readFileSync40(captureFile, "utf8").split("\n").filter(Boolean);
23515
+ const lines2 = readFileSync41(captureFile, "utf8").split("\n").filter(Boolean);
23336
23516
  const entries = [];
23337
23517
  for (const line of lines2) {
23338
23518
  let entry;
@@ -23906,7 +24086,7 @@ import { tmpdir as tmpdir6 } from "os";
23906
24086
  import { join as join63 } from "path";
23907
24087
 
23908
24088
  // src/commands/prs/loadCommentsCache.ts
23909
- import { existsSync as existsSync54, readFileSync as readFileSync41, unlinkSync as unlinkSync13 } from "fs";
24089
+ import { existsSync as existsSync54, readFileSync as readFileSync42, unlinkSync as unlinkSync13 } from "fs";
23910
24090
  import { parse as parse2 } from "yaml";
23911
24091
 
23912
24092
  // src/commands/prs/commentsCachePath.ts
@@ -23929,7 +24109,7 @@ function loadCommentsCache(org, repo, prNumber) {
23929
24109
  if (!existsSync54(cachePath)) {
23930
24110
  return null;
23931
24111
  }
23932
- const content = readFileSync41(cachePath, "utf8");
24112
+ const content = readFileSync42(cachePath, "utf8");
23933
24113
  return parse2(content);
23934
24114
  }
23935
24115
  function deleteCommentsCache(org, repo, prNumber) {
@@ -24121,7 +24301,7 @@ function fetchLineComments(org, repo, prNumber, threadInfo) {
24121
24301
  // src/commands/prs/listComments/updateCommentsCache.ts
24122
24302
  import { mkdirSync as mkdirSync19, writeFileSync as writeFileSync36 } from "fs";
24123
24303
  import { dirname as dirname29 } from "path";
24124
- import { stringify } from "yaml";
24304
+ import { stringify as stringify2 } from "yaml";
24125
24305
 
24126
24306
  // src/commands/prs/removeStaleCommentsCaches.ts
24127
24307
  import { readdirSync as readdirSync12, unlinkSync as unlinkSync16 } from "fs";
@@ -24149,7 +24329,7 @@ function writeCommentsCache(org, repo, prNumber, comments3) {
24149
24329
  fetchedAt: (/* @__PURE__ */ new Date()).toISOString(),
24150
24330
  comments: comments3
24151
24331
  };
24152
- writeFileSync36(cachePath, stringify(cacheData));
24332
+ writeFileSync36(cachePath, stringify2(cacheData));
24153
24333
  }
24154
24334
  function updateCommentsCache(org, repo, prNumber, comments3) {
24155
24335
  removeStaleCommentsCaches();
@@ -27481,7 +27661,7 @@ function gatherContext() {
27481
27661
  }
27482
27662
 
27483
27663
  // src/commands/review/postReviewToPr.ts
27484
- import { readFileSync as readFileSync42 } from "fs";
27664
+ import { readFileSync as readFileSync43 } from "fs";
27485
27665
 
27486
27666
  // src/commands/review/carriedUnanchoredFindings.ts
27487
27667
  function carriedUnanchoredFindings(unanchored) {
@@ -27929,7 +28109,7 @@ async function confirmPost(prNumber, work, options2) {
27929
28109
  return promptConfirm(`Post ${work} to PR #${prNumber}?`, false);
27930
28110
  }
27931
28111
  async function postFindingsToPr(prInfo, synthesisPath, options2) {
27932
- const markdown = readFileSync42(synthesisPath, "utf8");
28112
+ const markdown = readFileSync43(synthesisPath, "utf8");
27933
28113
  const { inDiff, unanchored } = selectPostableFindings(markdown, prInfo);
27934
28114
  const carried = carriedUnanchoredFindings(unanchored);
27935
28115
  if (inDiff.length === 0 && carried.length === 0) return NOTHING_POSTED;
@@ -28818,7 +28998,7 @@ async function runReviewers(reviewDir, claudePath, codexPath, stdinPrompt, optio
28818
28998
  }
28819
28999
 
28820
29000
  // src/commands/review/synthesise.ts
28821
- import { readFileSync as readFileSync43 } from "fs";
29001
+ import { readFileSync as readFileSync44 } from "fs";
28822
29002
 
28823
29003
  // src/commands/review/buildSynthesisStdin.ts
28824
29004
  var SYNTHESIS_PROMPT = `You are consolidating two independent code reviews of the same change. The original review request is in request.md. The two reviews are in claude.md and codex.md in the current working directory.
@@ -28883,7 +29063,7 @@ Files:
28883
29063
 
28884
29064
  // src/commands/review/synthesise.ts
28885
29065
  function printSummary2(synthesisPath) {
28886
- const markdown = readFileSync43(synthesisPath, "utf8");
29066
+ const markdown = readFileSync44(synthesisPath, "utf8");
28887
29067
  console.log("");
28888
29068
  console.log(buildReviewSummary(markdown));
28889
29069
  console.log("");
@@ -30246,7 +30426,7 @@ function list4() {
30246
30426
  import {
30247
30427
  existsSync as existsSync63,
30248
30428
  mkdirSync as mkdirSync26,
30249
- readFileSync as readFileSync48,
30429
+ readFileSync as readFileSync49,
30250
30430
  renameSync as renameSync2,
30251
30431
  writeFileSync as writeFileSync42
30252
30432
  } from "fs";
@@ -30458,7 +30638,7 @@ function formatChatLog(messages) {
30458
30638
  // src/commands/transcript/move.ts
30459
30639
  var DATE_REGEX = /^\d{4}-\d{2}-\d{2}$/;
30460
30640
  function convertVttToMarkdown(inputPath) {
30461
- const cues = parseVtt(readFileSync48(inputPath, "utf8"));
30641
+ const cues = parseVtt(readFileSync49(inputPath, "utf8"));
30462
30642
  const messages = cuesToChatMessages(deduplicateCues(cues));
30463
30643
  return formatChatLog(messages);
30464
30644
  }
@@ -30605,14 +30785,14 @@ function devices() {
30605
30785
  }
30606
30786
 
30607
30787
  // src/commands/voice/logs.ts
30608
- import { existsSync as existsSync64, readFileSync as readFileSync49 } from "fs";
30788
+ import { existsSync as existsSync64, readFileSync as readFileSync50 } from "fs";
30609
30789
  function logs(options2) {
30610
30790
  if (!existsSync64(voicePaths.log)) {
30611
30791
  console.log("No voice log file found");
30612
30792
  return;
30613
30793
  }
30614
30794
  const count8 = Number.parseInt(options2.lines ?? "150", 10);
30615
- const content = readFileSync49(voicePaths.log, "utf8").trim();
30795
+ const content = readFileSync50(voicePaths.log, "utf8").trim();
30616
30796
  if (!content) {
30617
30797
  console.log("Voice log is empty");
30618
30798
  return;
@@ -30639,7 +30819,7 @@ import { join as join82 } from "path";
30639
30819
 
30640
30820
  // src/commands/voice/checkLockFile.ts
30641
30821
  import { execSync as execSync58 } from "child_process";
30642
- import { existsSync as existsSync65, mkdirSync as mkdirSync27, readFileSync as readFileSync50, writeFileSync as writeFileSync43 } from "fs";
30822
+ import { existsSync as existsSync65, mkdirSync as mkdirSync27, readFileSync as readFileSync51, writeFileSync as writeFileSync43 } from "fs";
30643
30823
  import { join as join81 } from "path";
30644
30824
  function isProcessAlive2(pid) {
30645
30825
  try {
@@ -30653,7 +30833,7 @@ function checkLockFile() {
30653
30833
  const lockFile = getLockFile();
30654
30834
  if (!existsSync65(lockFile)) return;
30655
30835
  try {
30656
- const lock2 = JSON.parse(readFileSync50(lockFile, "utf8"));
30836
+ const lock2 = JSON.parse(readFileSync51(lockFile, "utf8"));
30657
30837
  if (lock2.pid && isProcessAlive2(lock2.pid)) {
30658
30838
  console.error(
30659
30839
  `Voice daemon already running (PID ${lock2.pid}, env: ${lock2.env}). Stop it first with: assist voice stop`
@@ -30755,7 +30935,7 @@ function start2(options2) {
30755
30935
  }
30756
30936
 
30757
30937
  // src/commands/voice/status.ts
30758
- import { existsSync as existsSync66, readFileSync as readFileSync51 } from "fs";
30938
+ import { existsSync as existsSync66, readFileSync as readFileSync52 } from "fs";
30759
30939
  function isProcessAlive3(pid) {
30760
30940
  try {
30761
30941
  process.kill(pid, 0);
@@ -30766,7 +30946,7 @@ function isProcessAlive3(pid) {
30766
30946
  }
30767
30947
  function readRecentLogs(count8) {
30768
30948
  if (!existsSync66(voicePaths.log)) return [];
30769
- const lines2 = readFileSync51(voicePaths.log, "utf8").trim().split("\n");
30949
+ const lines2 = readFileSync52(voicePaths.log, "utf8").trim().split("\n");
30770
30950
  return lines2.slice(-count8);
30771
30951
  }
30772
30952
  function status2() {
@@ -30774,7 +30954,7 @@ function status2() {
30774
30954
  console.log("Voice daemon: not running (no PID file)");
30775
30955
  return;
30776
30956
  }
30777
- const pid = Number.parseInt(readFileSync51(voicePaths.pid, "utf8").trim(), 10);
30957
+ const pid = Number.parseInt(readFileSync52(voicePaths.pid, "utf8").trim(), 10);
30778
30958
  const alive = isProcessAlive3(pid);
30779
30959
  console.log(`Voice daemon: ${alive ? "running" : "dead"} (PID ${pid})`);
30780
30960
  const recent = readRecentLogs(5);
@@ -30793,13 +30973,13 @@ function status2() {
30793
30973
  }
30794
30974
 
30795
30975
  // src/commands/voice/stop.ts
30796
- import { existsSync as existsSync67, readFileSync as readFileSync52, unlinkSync as unlinkSync20 } from "fs";
30976
+ import { existsSync as existsSync67, readFileSync as readFileSync53, unlinkSync as unlinkSync20 } from "fs";
30797
30977
  function stop2() {
30798
30978
  if (!existsSync67(voicePaths.pid)) {
30799
30979
  console.log("Voice daemon is not running (no PID file)");
30800
30980
  return;
30801
30981
  }
30802
- const pid = Number.parseInt(readFileSync52(voicePaths.pid, "utf8").trim(), 10);
30982
+ const pid = Number.parseInt(readFileSync53(voicePaths.pid, "utf8").trim(), 10);
30803
30983
  try {
30804
30984
  process.kill(pid, "SIGTERM");
30805
30985
  console.log(`Sent SIGTERM to voice daemon (PID ${pid})`);
@@ -31674,7 +31854,7 @@ async function auth() {
31674
31854
 
31675
31855
  // src/commands/roam/postRoamActivity.ts
31676
31856
  import { execFileSync as execFileSync18 } from "child_process";
31677
- import { readdirSync as readdirSync20, readFileSync as readFileSync53, statSync as statSync11 } from "fs";
31857
+ import { readdirSync as readdirSync20, readFileSync as readFileSync54, statSync as statSync11 } from "fs";
31678
31858
  import { join as join86 } from "path";
31679
31859
  function findPortFile(roamDir) {
31680
31860
  let entries;
@@ -31700,7 +31880,7 @@ function postRoamActivity(app, event) {
31700
31880
  if (!portFile) return;
31701
31881
  let port;
31702
31882
  try {
31703
- port = readFileSync53(portFile, "utf8").trim();
31883
+ port = readFileSync54(portFile, "utf8").trim();
31704
31884
  } catch {
31705
31885
  return;
31706
31886
  }
@@ -32232,11 +32412,11 @@ function applyLine(result, pending, line) {
32232
32412
  }
32233
32413
 
32234
32414
  // src/commands/sessions/daemon/readDaemonPidFile.ts
32235
- import { readFileSync as readFileSync54 } from "fs";
32415
+ import { readFileSync as readFileSync55 } from "fs";
32236
32416
  function readDaemonPidFile() {
32237
32417
  try {
32238
32418
  const pid = Number.parseInt(
32239
- readFileSync54(daemonPaths.pid, "utf8").trim(),
32419
+ readFileSync55(daemonPaths.pid, "utf8").trim(),
32240
32420
  10
32241
32421
  );
32242
32422
  return Number.isInteger(pid) ? pid : void 0;
@@ -36267,14 +36447,14 @@ async function defaultConnect() {
36267
36447
  }
36268
36448
 
36269
36449
  // src/commands/sessions/daemon/hasPersistedWindowsSessions.ts
36270
- import { existsSync as existsSync84, readFileSync as readFileSync56 } from "fs";
36450
+ import { existsSync as existsSync84, readFileSync as readFileSync57 } from "fs";
36271
36451
  import { posix as posix3 } from "path";
36272
36452
  function hasPersistedWindowsSessions() {
36273
36453
  const sessionsFile = windowsSessionsFileFromWsl();
36274
36454
  if (!sessionsFile) return false;
36275
36455
  try {
36276
36456
  if (!existsSync84(sessionsFile)) return false;
36277
- const data = JSON.parse(readFileSync56(sessionsFile, "utf8"));
36457
+ const data = JSON.parse(readFileSync57(sessionsFile, "utf8"));
36278
36458
  return Array.isArray(data) && data.length > 0;
36279
36459
  } catch (error) {
36280
36460
  const message3 = error instanceof Error ? error.message : String(error);
@@ -37692,7 +37872,7 @@ function handleConnection(socket, manager) {
37692
37872
  import { unlinkSync as unlinkSync23, writeFileSync as writeFileSync47 } from "fs";
37693
37873
 
37694
37874
  // src/commands/sessions/daemon/startPidFileWatchdog.ts
37695
- import { readFileSync as readFileSync57 } from "fs";
37875
+ import { readFileSync as readFileSync58 } from "fs";
37696
37876
  var WATCHDOG_INTERVAL_MS = 5e3;
37697
37877
  function startPidFileWatchdog(onLost, intervalMs = WATCHDOG_INTERVAL_MS) {
37698
37878
  const timer = setInterval(() => {
@@ -37703,7 +37883,7 @@ function startPidFileWatchdog(onLost, intervalMs = WATCHDOG_INTERVAL_MS) {
37703
37883
  }
37704
37884
  function ownsPidFile() {
37705
37885
  try {
37706
- return readFileSync57(daemonPaths.pid, "utf8").trim() === String(process.pid);
37886
+ return readFileSync58(daemonPaths.pid, "utf8").trim() === String(process.pid);
37707
37887
  } catch {
37708
37888
  return false;
37709
37889
  }
@@ -38158,7 +38338,7 @@ function buildLimitsSegment(rateLimits) {
38158
38338
  }
38159
38339
 
38160
38340
  // src/commands/readGitBranch.ts
38161
- import { readFileSync as readFileSync59, statSync as statSync15 } from "fs";
38341
+ import { readFileSync as readFileSync60, statSync as statSync15 } from "fs";
38162
38342
  import { isAbsolute as isAbsolute4, join as join95, resolve as resolve22 } from "path";
38163
38343
  function resolveGitDir(cwd) {
38164
38344
  const dotGit = join95(cwd, ".git");
@@ -38173,7 +38353,7 @@ function resolveGitDir(cwd) {
38173
38353
  }
38174
38354
  let contents;
38175
38355
  try {
38176
- contents = readFileSync59(dotGit, "utf8");
38356
+ contents = readFileSync60(dotGit, "utf8");
38177
38357
  } catch {
38178
38358
  return null;
38179
38359
  }
@@ -38191,7 +38371,7 @@ function readGitBranch(cwd) {
38191
38371
  }
38192
38372
  let head;
38193
38373
  try {
38194
- head = readFileSync59(join95(gitDir, "HEAD"), "utf8");
38374
+ head = readFileSync60(join95(gitDir, "HEAD"), "utf8");
38195
38375
  } catch {
38196
38376
  return null;
38197
38377
  }
@@ -38318,7 +38498,7 @@ async function update2() {
38318
38498
  // src/reportCliError.ts
38319
38499
  import chalk221 from "chalk";
38320
38500
  function reportCliError(error) {
38321
- if (error instanceof InvalidItemIdError || error instanceof AmbiguousRepoConfigError || error instanceof UnknownRepoConfigError || error instanceof MissingRunCwdError) {
38501
+ if (error instanceof InvalidItemIdError || error instanceof AmbiguousRepoConfigError || error instanceof UnknownRepoConfigError || error instanceof MissingRunCwdError || error instanceof MiroExtractError) {
38322
38502
  console.error(chalk221.red(error.message));
38323
38503
  } else {
38324
38504
  console.error(error);
@@ -38362,6 +38542,7 @@ registerGithub(program);
38362
38542
  registerHandover(program);
38363
38543
  registerJira(program);
38364
38544
  registerMermaid(program);
38545
+ registerMiro(program);
38365
38546
  registerPrs(program);
38366
38547
  registerRoam(program);
38367
38548
  registerBacklog(program);
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@staff0rd/assist",
3
- "version": "0.576.0",
3
+ "version": "0.577.0",
4
4
  "type": "module",
5
5
  "main": "dist/index.js",
6
6
  "bin": {