litmus-cli 1.4.46 → 1.4.47
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/commands/connect.d.ts +110 -227
- package/dist/commands/connect.d.ts.map +1 -1
- package/dist/commands/connect.js +289 -517
- package/dist/commands/connect.js.map +1 -1
- package/dist/commands/init.d.ts +2 -1
- package/dist/commands/init.d.ts.map +1 -1
- package/dist/commands/init.js +2 -1
- package/dist/commands/init.js.map +1 -1
- package/dist/lib/connect-skills.d.ts +5 -1
- package/dist/lib/connect-skills.d.ts.map +1 -1
- package/dist/lib/connect-skills.js +6 -2
- package/dist/lib/connect-skills.js.map +1 -1
- package/dist/lib/cursor-restart.d.ts +1 -1
- package/dist/lib/cursor-restart.js +1 -1
- package/dist/lib/editor-server.d.ts +12 -4
- package/dist/lib/editor-server.d.ts.map +1 -1
- package/dist/lib/editor-server.js +30 -4
- package/dist/lib/editor-server.js.map +1 -1
- package/dist/lib/session-end.d.ts +5 -8
- package/dist/lib/session-end.d.ts.map +1 -1
- package/dist/lib/session-end.js +6 -12
- package/dist/lib/session-end.js.map +1 -1
- package/package.json +1 -1
|
@@ -167,8 +167,8 @@ export declare function aliasFor(sshHostname: string | null | undefined, token:
|
|
|
167
167
|
* `--list-extensions` does not report the Microsoft id, so we "install" it and announce
|
|
168
168
|
* "Installed the VS Code Remote-SSH extension", and `--remote` opens Cursor while we say
|
|
169
169
|
* we are opening VS Code. The candidate is then on Cursor's capture lane having never
|
|
170
|
-
* been
|
|
171
|
-
* capture.
|
|
170
|
+
* had Cursor restarted, or been asked to quit it, as that lane depends on (ENG-1728),
|
|
171
|
+
* which is silent zero capture.
|
|
172
172
|
*
|
|
173
173
|
* MEASURED 2026-09-04 on darwin arm64, VS Code 1.136.1 and Cursor 3.18.25, with a `code`
|
|
174
174
|
* symlinked to Cursor's CLI to reproduce the report:
|
|
@@ -226,22 +226,14 @@ export interface NativeEditor {
|
|
|
226
226
|
* ENG-2332 — whether a PROVEN commit mismatch refuses the launch, or only explains a
|
|
227
227
|
* launch that then failed.
|
|
228
228
|
*
|
|
229
|
-
*
|
|
230
|
-
*
|
|
231
|
-
*
|
|
232
|
-
*
|
|
233
|
-
*
|
|
234
|
-
*
|
|
235
|
-
*
|
|
236
|
-
*
|
|
237
|
-
* So for Cursor a mismatch is a refusal: the measured outcome is a window that looks
|
|
238
|
-
* normal, is served by a LOCAL extension host, and records nothing, which is the worst
|
|
239
|
-
* thing this product can do to a candidate. For VS Code it is a note kept back and used
|
|
240
|
-
* to explain a failed verification, because refusing there would take away a path that
|
|
241
|
-
* works today on the strength of a fault that has never been seen on it.
|
|
242
|
-
*
|
|
243
|
-
* This flips to `false` for Cursor the day the mirror is measured serving a drifted
|
|
244
|
-
* Cursor client — not before, and not on the strength of it looking like it should.
|
|
229
|
+
* ENG-2884 / ENG-2890: false for both editors. Cursor used to be refused, on the
|
|
230
|
+
* strength of ENG-1936 and ENG-2332, where a drifted client never reached the mirror.
|
|
231
|
+
* Measured 2026-10-01: Cursor 3.19.13 (older than the workspace), 3.22.12 (a match) and
|
|
232
|
+
* 3.23.12 (newer) each fetched its own server through the mirror into
|
|
233
|
+
* `~/.cursor-server/bin/linux-x64/<commit>`, attached, and had its prompt captured. The
|
|
234
|
+
* refusal only turned away editors that work. `verifyEditorAttached`, after the launch,
|
|
235
|
+
* is the guard against a window that never attached; the flag and the `refused` branch
|
|
236
|
+
* stay so an editor measured failing again can be refused without new plumbing.
|
|
245
237
|
*/
|
|
246
238
|
requiresSeedMatch: boolean;
|
|
247
239
|
}
|
|
@@ -304,152 +296,80 @@ export declare function identifyEditorBanner(helpOutput: string): NativeIde | nu
|
|
|
304
296
|
/** How the identity probe reaches the binary. Injected so the verdicts are testable. */
|
|
305
297
|
export type EditorHelpRunner = (bin: string) => string | null;
|
|
306
298
|
export declare function identifyEditorCli(ed: NativeEditor, command: string, run?: EditorHelpRunner): EditorIdentity;
|
|
299
|
+
/**
|
|
300
|
+
* The route that needs nothing else to work: the browser IDE, reached from the page,
|
|
301
|
+
* or the alias we have just written into their ~/.ssh/config.
|
|
302
|
+
*/
|
|
303
|
+
export declare function workNowLine(alias: string, pageUrl: string | null): string;
|
|
307
304
|
/**
|
|
308
305
|
* ENG-2152 — the refusal, when the command the candidate's PATH answers with is the
|
|
309
|
-
* other editor.
|
|
310
|
-
*
|
|
311
|
-
*
|
|
312
|
-
*
|
|
313
|
-
*
|
|
314
|
-
|
|
315
|
-
|
|
316
|
-
|
|
317
|
-
*
|
|
318
|
-
*
|
|
319
|
-
*
|
|
320
|
-
*
|
|
321
|
-
*
|
|
322
|
-
*
|
|
323
|
-
*
|
|
324
|
-
* reference to output the candidate is about to see, not ENG-2145's back-reference to
|
|
325
|
-
* output that has scrolled away. Restating the whole block here would also have to
|
|
326
|
-
* restate its "this command is still running and will open Cursor for you", which on
|
|
327
|
-
* this path is false.
|
|
328
|
-
*/
|
|
329
|
-
export declare function editorMismatchLines(chosen: NativeEditor, actual: NativeEditor, reentry?: CursorReentry): string[];
|
|
330
|
-
/**
|
|
331
|
-
* ENG-2332 — the refusal when the candidate's editor is a different build from the one
|
|
332
|
-
* this workspace has, and the route to the workspace that still works.
|
|
333
|
-
*
|
|
334
|
-
* What it must never do is offer a way round the refusal: there is no flag and no "open
|
|
335
|
-
* it anyway", since the thing on the other side of that door is a window that looks
|
|
336
|
-
* completely normal and records nothing (`lib/editor-server.ts` carries the measurement).
|
|
337
|
-
*
|
|
338
|
-
* ENG-2867 — but it must say the one thing that DOES change the verdict, and say it first.
|
|
339
|
-
* The image bakes the latest Stable build at image build time and Cursor ships about
|
|
340
|
-
* weekly, so the usual mismatch is a candidate one release behind, and updating is what
|
|
341
|
-
* clears it. The ENG-2332 cut never said so. A candidate who had just been told to quit
|
|
342
|
-
* Cursor read that as the remedy and re-ran the same refused command four times. So the
|
|
343
|
-
* order is: what to do, that retrying without it will not help, the exact command to run
|
|
344
|
-
* after, and only then why. The "why" is one sentence; it used to be the whole notice.
|
|
345
|
-
*
|
|
346
|
-
* Update is not guaranteed to land on the baked build: an image built before the newest
|
|
347
|
-
* release is refused again after updating, since `seedVerdict` wants an exact commit. So
|
|
348
|
-
* the copy says "usually", names that outcome as step 4, and the routes that need no
|
|
349
|
-
* update follow it (Greptile on #3033). Step 4 diagnoses nothing: the check compares
|
|
350
|
-
* commits, and a second refusal has more causes (an older image, a second install found
|
|
351
|
-
* first) than a notice can tell apart. The routes below always work, so step 4 sends the
|
|
352
|
-
* candidate there and states only the one fact the version line proves.
|
|
306
|
+
* other editor. Nothing has been opened and no extension installed when this prints.
|
|
307
|
+
*
|
|
308
|
+
* The editor that answered comes first: on a machine where `code` is Cursor, Cursor is
|
|
309
|
+
* almost certainly the daily driver and VS Code may not be installed at all. The PATH
|
|
310
|
+
* fix follows in one line, then the routes that need neither.
|
|
311
|
+
*/
|
|
312
|
+
export declare function editorMismatchLines(chosen: NativeEditor, actual: NativeEditor, alias: string, pageUrl: string | null): string[];
|
|
313
|
+
/**
|
|
314
|
+
* ENG-2332 — the refusal when the candidate's editor is a different build from the one
|
|
315
|
+
* this workspace has.
|
|
316
|
+
*
|
|
317
|
+
* ENG-2884: no editor sets `requiresSeedMatch` any more, so this is reachable only if one
|
|
318
|
+
* is measured failing again and the flag goes back on. Kept short for that day: what
|
|
319
|
+
* happened, that updating usually clears it, and the routes that need no update. There is
|
|
320
|
+
* deliberately no "open it anyway".
|
|
353
321
|
*/
|
|
354
322
|
export declare function editorSeedMismatchLines(ed: NativeEditor, verdict: Extract<SeedVerdict, {
|
|
355
323
|
kind: "mismatch";
|
|
356
|
-
}>,
|
|
324
|
+
}>, pageUrl: string | null, alias: string): string[];
|
|
357
325
|
/**
|
|
358
326
|
* ENG-2332 — what to say when the editor CLI cannot be found anywhere.
|
|
359
327
|
*
|
|
360
|
-
*
|
|
361
|
-
*
|
|
362
|
-
*
|
|
363
|
-
*
|
|
364
|
-
|
|
365
|
-
|
|
366
|
-
|
|
367
|
-
|
|
368
|
-
*
|
|
369
|
-
*
|
|
370
|
-
*
|
|
371
|
-
*
|
|
372
|
-
*
|
|
373
|
-
*
|
|
374
|
-
*
|
|
375
|
-
|
|
376
|
-
|
|
377
|
-
|
|
378
|
-
*
|
|
379
|
-
*
|
|
380
|
-
*
|
|
381
|
-
|
|
382
|
-
|
|
383
|
-
|
|
384
|
-
*
|
|
385
|
-
*
|
|
386
|
-
*
|
|
387
|
-
*
|
|
388
|
-
|
|
389
|
-
|
|
390
|
-
|
|
391
|
-
*
|
|
392
|
-
*
|
|
393
|
-
*
|
|
394
|
-
*
|
|
395
|
-
|
|
396
|
-
|
|
397
|
-
|
|
398
|
-
*
|
|
399
|
-
*
|
|
400
|
-
*
|
|
401
|
-
*
|
|
402
|
-
*
|
|
403
|
-
|
|
404
|
-
|
|
405
|
-
* routes rather than instructing an exit. What it still may not do is tell them to re-run
|
|
406
|
-
* this command, which is the original bug.
|
|
407
|
-
*
|
|
408
|
-
* AND IT MAY NOT HAND THEM A CHECK THAT PASSES ON THE DEAD WINDOW. It pointed at the
|
|
409
|
-
* remote indicator — "the bottom-left corner reads SSH: <alias>" — and this repo has
|
|
410
|
-
* measured that indicator PRESENT in exactly the failure case: `lib/editor-server.ts`'s
|
|
411
|
-
* header records the never-attached window carrying `"remoteAuthority":
|
|
412
|
-
* "ssh-remote+<alias>"` and being indistinguishable from a working one, and
|
|
413
|
-
* `lib/session-end.ts` records (ENG-2154) that a window whose transport is gone still
|
|
414
|
-
* reads `[SSH: <host>]`. A candidate told to look at the corner sees what they were told
|
|
415
|
-
* to look for and goes on working unrecorded, which is this ticket's own bug re-entering
|
|
416
|
-
* through its remediation. The honest sentence is that the two windows look the same —
|
|
417
|
-
* that is WHY the CLI checks — so the copy says so and names no visual test at all.
|
|
418
|
-
*/
|
|
419
|
-
export declare function editorNotConnectedLines(ed: NativeEditor, alias: string, browserIdeUrl: string | null, seed: SeedVerdict, launchLog: string | null): string[];
|
|
420
|
-
/**
|
|
421
|
-
* ENG-2332 — what to say when the editor never started at all.
|
|
422
|
-
*
|
|
423
|
-
* THIS BRANCH EXISTS BECAUSE THE ONE ABOVE MUST NOT BE REACHABLE WITHOUT A WINDOW.
|
|
424
|
-
* `editorNotConnectedLines` opens by stating, as a fact, that a window is on screen and
|
|
425
|
-
* running against the candidate's own machine; when `spawn` itself fails that sentence is
|
|
426
|
-
* false, and the reading the verification produces is identical either way (no server,
|
|
427
|
-
* empty launch log). So the spawn error is recorded (`EditorLaunchHandle`) and routed
|
|
428
|
-
* here instead, where the only claim made is the one we can support.
|
|
429
|
-
*
|
|
430
|
-
* It offers the same two routes and, like every other failure branch, offers rather than
|
|
431
|
-
* instructs: there is no window to close, and re-running this command is the remediation
|
|
432
|
-
* the ticket was opened about. The error text is carried verbatim because it is the whole
|
|
433
|
-
* of what we know — `ENOENT` on a resolved path means the app moved or was removed since
|
|
434
|
-
* the `--version` probe a moment earlier, which is a thing the candidate can act on and
|
|
435
|
-
* we cannot diagnose for them.
|
|
436
|
-
*/
|
|
437
|
-
export declare function editorLaunchFailedLines(ed: NativeEditor, alias: string, browserIdeUrl: string | null, error: string, launchLog: string | null): string[];
|
|
438
|
-
/**
|
|
439
|
-
* ENG-2332 — what to say when we could not reach the workspace to ask at all.
|
|
440
|
-
*
|
|
441
|
-
* Three-valued on purpose: "we could not check" is not "nothing came up", and saying
|
|
442
|
-
* either of the other two here would be a claim we cannot make. It lives beside the other
|
|
443
|
-
* copy rather than inline in `runConnect` so that what it may and may not say is testable
|
|
444
|
-
* — it is bound by the same rule as `editorNotConnectedLines` and broke it the same way.
|
|
445
|
-
*
|
|
446
|
-
* It may NOT tell the candidate to look at the remote indicator. That indicator is
|
|
447
|
-
* rendered from the remote authority, which the never-attached window carries (see
|
|
448
|
-
* `lib/editor-server.ts`'s header, and ENG-2154 in `lib/session-end.ts`), so the check
|
|
449
|
-
* passes in exactly the case it was offered to detect. It states the ambiguity instead
|
|
450
|
-
* and offers the two routes that are not in doubt.
|
|
451
|
-
*/
|
|
452
|
-
export declare function editorUnverifiedLines(ed: NativeEditor, alias: string, browserIdeUrl: string | null): string[];
|
|
328
|
+
* Never `<bin> --remote …`: that is the binary whose absence is the message. Everything
|
|
329
|
+
* here works without it: the editor's own Remote-SSH picker (the alias is already in
|
|
330
|
+
* their `~/.ssh/config`), the palette command that puts the CLI on PATH, and the routes
|
|
331
|
+
* that need no editor.
|
|
332
|
+
*/
|
|
333
|
+
export declare function editorNotFoundLines(ed: NativeEditor, alias: string, pageUrl: string | null): string[];
|
|
334
|
+
/**
|
|
335
|
+
* ENG-2332 — the footer under the verified success line.
|
|
336
|
+
*
|
|
337
|
+
* ENG-2890: for Cursor, one line naming the window that IS connected, since a restart
|
|
338
|
+
* can leave the candidate's other Cursor windows reopening beside it. The window title
|
|
339
|
+
* is safe to name here and only here: this prints after `verifyEditorAttached` saw a
|
|
340
|
+
* server, unlike the failure branches, where the never-attached window carries the same
|
|
341
|
+
* `[SSH: <alias>]` (ENG-2154). The workspace path is for whoever is debugging, so it is
|
|
342
|
+
* `--verbose` only. VS Code needs no footer.
|
|
343
|
+
*/
|
|
344
|
+
export declare function editorConnectedLines(ed: NativeEditor, alias: string, verbose?: boolean, platform?: NodeJS.Platform): string[];
|
|
345
|
+
/**
|
|
346
|
+
* ENG-2332 — a window opened and no server came up in the workspace, so that window is
|
|
347
|
+
* running against the candidate's own machine and records nothing.
|
|
348
|
+
*
|
|
349
|
+
* ENG-2890: four lines. Close the window, retry with the cause that usually explains it
|
|
350
|
+
* (an editor that stopped to ask for a sign-in or an update), or work elsewhere now.
|
|
351
|
+
*
|
|
352
|
+
* IT MAY NOT HAND THEM A CHECK THAT PASSES ON THE DEAD WINDOW. The remote indicator
|
|
353
|
+
* ("SSH: <alias>" in the corner) is PRESENT on the never-attached window
|
|
354
|
+
* (`lib/editor-server.ts`'s header; ENG-2154 in `lib/session-end.ts`), so no visual test
|
|
355
|
+
* is named here at all.
|
|
356
|
+
*/
|
|
357
|
+
export declare function editorNotConnectedLines(ed: NativeEditor, alias: string, pageUrl: string | null, verbose?: boolean): string[];
|
|
358
|
+
/**
|
|
359
|
+
* ENG-2332 — the editor never started at all, so no window exists.
|
|
360
|
+
*
|
|
361
|
+
* Its own branch because `editorNotConnectedLines` tells them to close a window, which
|
|
362
|
+
* is false when `spawn` failed. The error is carried verbatim: it is all we know.
|
|
363
|
+
*/
|
|
364
|
+
export declare function editorLaunchFailedLines(ed: NativeEditor, alias: string, pageUrl: string | null, error: string, verbose?: boolean): string[];
|
|
365
|
+
/**
|
|
366
|
+
* ENG-2332 — we could not reach the workspace to ask, which is not "nothing came up".
|
|
367
|
+
*
|
|
368
|
+
* It may NOT offer the remote indicator as a check (ENG-2154: the never-attached window
|
|
369
|
+
* carries it). The file explorer is a fair one: a window not attached to the workspace
|
|
370
|
+
* has no workspace files to list.
|
|
371
|
+
*/
|
|
372
|
+
export declare function editorUnverifiedLines(ed: NativeEditor, alias: string, pageUrl: string | null): string[];
|
|
453
373
|
/**
|
|
454
374
|
* ENG-2332 — where the editor's own output goes.
|
|
455
375
|
*
|
|
@@ -531,10 +451,8 @@ export interface EditorLaunchHandle {
|
|
|
531
451
|
*/
|
|
532
452
|
export declare function launchEditor(ed: NativeEditor, command: string, alias: string, logPath: string): EditorLaunchHandle;
|
|
533
453
|
/**
|
|
534
|
-
* Point at the editor's own output
|
|
535
|
-
*
|
|
536
|
-
* `--verbose` was asked for, since `editorLaunchLogPath` gives it a per-run suffix that
|
|
537
|
-
* nobody can guess unaided.
|
|
454
|
+
* Point at the editor's own output, under `--verbose` only (ENG-2890: the failure copy
|
|
455
|
+
* says "Details: add --verbose." instead of printing a path by default).
|
|
538
456
|
*
|
|
539
457
|
* A PATH IS NAMED ONLY WHEN THERE IS SOMETHING AT IT, and the reason is that the file
|
|
540
458
|
* routinely does not exist. `launchEditor` falls back to `stdio: "ignore"` whenever
|
|
@@ -544,7 +462,7 @@ export declare function launchEditor(ed: NativeEditor, command: string, alias: s
|
|
|
544
462
|
* Handing a support person a path with nothing behind it reads as the CLI having lost
|
|
545
463
|
* the log, which is a worse answer than saying plainly that the editor wrote nothing.
|
|
546
464
|
*/
|
|
547
|
-
export declare function editorLaunchOutputLines(logPath: string, launchLog: string | null, verbose: boolean
|
|
465
|
+
export declare function editorLaunchOutputLines(logPath: string, launchLog: string | null, verbose: boolean): string[];
|
|
548
466
|
/**
|
|
549
467
|
* ENG-2332 — one reading of the workspace, over the alias we have just written.
|
|
550
468
|
*
|
|
@@ -554,7 +472,7 @@ export declare function editorLaunchOutputLines(logPath: string, launchLog: stri
|
|
|
554
472
|
* never as "there is no server" — see `verifyVerdict`.
|
|
555
473
|
*/
|
|
556
474
|
export type WorkspaceProbeRunner = (remoteCommand: string) => string | null;
|
|
557
|
-
export declare function verifyEditorAttached(ed: NativeEditor, baseline: WorkspaceProbe | null, run: WorkspaceProbeRunner, onWait: (secondsWaited: number) => void, launched: EditorLaunchHandle): Promise<VerifyVerdict>;
|
|
475
|
+
export declare function verifyEditorAttached(ed: NativeEditor, baseline: WorkspaceProbe | null, run: WorkspaceProbeRunner, onWait: (secondsWaited: number) => void, launched: EditorLaunchHandle, clientCommit?: string | null): Promise<VerifyVerdict>;
|
|
558
476
|
/** Whether the editor's Remote-SSH extension was already there, put there, or could not be. */
|
|
559
477
|
export type RemoteSshExtensionState = "present" | "installed" | "failed";
|
|
560
478
|
/**
|
|
@@ -621,16 +539,10 @@ export type IdeChoice = "vscode" | "cursor" | "browser" | "ssh";
|
|
|
621
539
|
* (piped / CI), so scripted runs never block on the prompt.
|
|
622
540
|
*
|
|
623
541
|
* `log` is injectable ONLY so that the Cursor notice below is testable through the real
|
|
624
|
-
* selection path rather than by reading a string constant
|
|
625
|
-
*
|
|
626
|
-
* it was printed is not a test of it.
|
|
627
|
-
*
|
|
628
|
-
* `reentry` is the way back in, and it is threaded from `runConnect` rather than
|
|
629
|
-
* rebuilt here because only the caller holds the token and the resolved base. When it
|
|
630
|
-
* is absent (a test, a scripted call) the notice degrades to the placeholder form
|
|
631
|
-
* rather than dropping the route — see `cursorReentryLines`.
|
|
542
|
+
* selection path rather than by reading a string constant, and `platform` so that both
|
|
543
|
+
* of its forms are (see `cursorSelectionNoticeLines`).
|
|
632
544
|
*/
|
|
633
|
-
export declare function resolveIde(flag: string | undefined, log?: (line: string) => void,
|
|
545
|
+
export declare function resolveIde(flag: string | undefined, log?: (line: string) => void, platform?: NodeJS.Platform): Promise<{
|
|
634
546
|
ide: IdeChoice;
|
|
635
547
|
chosen: boolean;
|
|
636
548
|
}>;
|
|
@@ -663,69 +575,40 @@ export declare function keepWaitingForWorkspace(elapsedMs: number, status: strin
|
|
|
663
575
|
*/
|
|
664
576
|
export declare function candidatePageUrl(apiBase: string, assessmentId: string): string;
|
|
665
577
|
/**
|
|
666
|
-
*
|
|
578
|
+
* ENG-1950 — the one thing a Cursor candidate has to be told when they pick Cursor.
|
|
667
579
|
*
|
|
668
|
-
*
|
|
669
|
-
*
|
|
670
|
-
*
|
|
671
|
-
* `
|
|
672
|
-
*
|
|
580
|
+
* Cursor reads its prompt-recording setup once, at application startup (ENG-1728,
|
|
581
|
+
* measured), so a Cursor that is already open when the workspace opens records no AI
|
|
582
|
+
* prompts while everything else works. ENG-2890: on macOS connect quits and reopens
|
|
583
|
+
* Cursor itself (`lib/cursor-restart.ts`), so nothing is said here and the restart step
|
|
584
|
+
* speaks when it acts. Elsewhere a graceful quit cannot be confirmed, so the candidate is
|
|
585
|
+
* asked to do it, in two lines: the 23-line notice this replaced was the wall the
|
|
586
|
+
* ENG-2890 candidate read past. The second line exists because quitting Cursor also
|
|
587
|
+
* closes its integrated terminal, and with it this command (ENG-2145).
|
|
673
588
|
*/
|
|
674
|
-
export
|
|
675
|
-
command: string;
|
|
676
|
-
pageUrl: string | null;
|
|
677
|
-
}
|
|
589
|
+
export declare function cursorSelectionNoticeLines(platform?: NodeJS.Platform): string[];
|
|
678
590
|
/**
|
|
679
|
-
* ENG-
|
|
591
|
+
* ENG-2890 — is this process running in Cursor's integrated terminal?
|
|
680
592
|
*
|
|
681
|
-
*
|
|
682
|
-
*
|
|
683
|
-
*
|
|
684
|
-
*
|
|
685
|
-
*
|
|
686
|
-
* is the one route the instruction above it destroys. A candidate told to quit Cursor is
|
|
687
|
-
* very likely reading the instruction IN CURSOR'S OWN INTEGRATED TERMINAL, because that
|
|
688
|
-
* is where they have a shell; `Cmd+Q` then takes `litmus connect` with it. What is left
|
|
689
|
-
* on screen is a quit editor, no running command, and nothing anywhere naming the way
|
|
690
|
-
* back. On the clock, that reads as the workspace being gone.
|
|
691
|
-
*
|
|
692
|
-
* So the route is stated as an instruction rather than as a promise about a process that
|
|
693
|
-
* may no longer exist, and the terminal it must be run from is named: a candidate who
|
|
694
|
-
* has just been told to quit an application cannot be told to use that application's
|
|
695
|
-
* terminal. The assessment page comes second and is the one that survives closing the
|
|
696
|
-
* tab AND losing the terminal, which is the state Elena was actually in.
|
|
697
|
-
*
|
|
698
|
-
* Both routes reopen the SAME workspace — `litmus connect` re-registers this machine's
|
|
699
|
-
* key and wakes a parked container through the ENG-2005 machinery, and the portal's own
|
|
700
|
-
* card does the same — so the reassurance is a fact about the platform, not a hope.
|
|
593
|
+
* Quitting Cursor kills its terminals, so the macOS auto-restart would kill this CLI
|
|
594
|
+
* between the quit and the relaunch, leaving no editor and no command. `TERM_PROGRAM`
|
|
595
|
+
* is "vscode" in VS Code AND in Cursor's terminal, so one of Cursor's own markers is
|
|
596
|
+
* required as well: its trace id, its ToDesktop bundle id, or its bundled askpass node.
|
|
597
|
+
* VS Code's terminal (bundle id `com.microsoft.VSCode`, no trace id) is not a match.
|
|
701
598
|
*/
|
|
702
|
-
export declare function
|
|
599
|
+
export declare function runningInsideCursorTerminal(env?: NodeJS.ProcessEnv): boolean;
|
|
600
|
+
/** ENG-2890 — said instead of quitting Cursor out from under this terminal. */
|
|
601
|
+
export declare function insideCursorTerminalLines(): string[];
|
|
602
|
+
/** ENG-2890 — the one line connect prints before its macOS auto-restart of Cursor. */
|
|
603
|
+
/** Cursor success when this command could not confirm a fresh start (gotcha 090). */
|
|
604
|
+
export declare const CURSOR_RECORDING_CAVEAT_LINE = " Your AI prompts are recorded only if Cursor was fully quit before it opened. If it wasn't, quit it and run the same litmus connect command again.";
|
|
605
|
+
export declare const CURSOR_RESTARTING_LINE = "Restarting Cursor so your AI prompts are recorded (it reopens on its own)...";
|
|
703
606
|
/**
|
|
704
|
-
* ENG-
|
|
705
|
-
*
|
|
706
|
-
*
|
|
707
|
-
* Cursor's hooks service reads its configuration ONCE, at application startup. Not on a
|
|
708
|
-
* window reload, not on a fresh Remote-SSH connection. Our prompt capture for Cursor is
|
|
709
|
-
* such a hook (staged into the container by `litmus-firstboot` §5b, ENG-1728), so a
|
|
710
|
-
* candidate who connects from an already-running Cursor gets a session where the hook is
|
|
711
|
-
* present, correct, and never loaded.
|
|
712
|
-
*
|
|
713
|
-
* That failure is entirely silent. The editor connects, the workspace works, files save,
|
|
714
|
-
* the AI answers — and nothing is recorded, so their Process dimension is graded on an
|
|
715
|
-
* empty record. It cost about an hour of investigation on 2026-08-28 to diagnose from
|
|
716
|
-
* the inside, with the container in hand; a candidate has no chance of noticing at all.
|
|
717
|
-
*
|
|
718
|
-
* So the copy is written for a candidate, not for us: what to do, and what it costs if
|
|
719
|
-
* they don't. No "hooks", no "capture lane". The mechanism is our problem.
|
|
720
|
-
*
|
|
721
|
-
* ENG-2145 adds the second half of that sentence: what to do is now "quit, THEN run
|
|
722
|
-
* this", because an instruction to quit with no stated way back is what sent two people
|
|
723
|
-
* who know the product looking for their workspace. The order is deliberate — the cost
|
|
724
|
-
* of skipping the quit still comes last, so the thing a candidate acts on immediately is
|
|
725
|
-
* the thing they read first, and `cursorReentryLines` sits between them rather than
|
|
726
|
-
* after the whole notice where it would scroll.
|
|
607
|
+
* ENG-2890 — the quit was asked for and Cursor is still running, so nothing is
|
|
608
|
+
* launched (see the gate in `connectFlow`). `renderCursorRestartOutcome`'s longer form
|
|
609
|
+
* stays with init and doctor.
|
|
727
610
|
*/
|
|
728
|
-
export declare function
|
|
611
|
+
export declare function cursorQuitUnconfirmedLines(): string[];
|
|
729
612
|
/**
|
|
730
613
|
* Map a menu answer to an editor. (ENG-1667 item 3; Cursor added by ENG-1950.)
|
|
731
614
|
*
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"connect.d.ts","sourceRoot":"","sources":["../../src/commands/connect.ts"],"names":[],"mappings":"AAcA,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,sBAAsB,CAAA;AACrD,OAAO,EAOL,KAAK,aAAa,EAClB,KAAK,WAAW,EAChB,KAAK,aAAa,EAClB,KAAK,cAAc,EACpB,MAAM,yBAAyB,CAAA;
|
|
1
|
+
{"version":3,"file":"connect.d.ts","sourceRoot":"","sources":["../../src/commands/connect.ts"],"names":[],"mappings":"AAcA,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,sBAAsB,CAAA;AACrD,OAAO,EAOL,KAAK,aAAa,EAClB,KAAK,WAAW,EAChB,KAAK,aAAa,EAClB,KAAK,cAAc,EACpB,MAAM,yBAAyB,CAAA;AAkDhC,MAAM,WAAW,SAAS;IACxB,IAAI,EAAE,MAAM,CAAA;IACZ,IAAI,EAAE,MAAM,CAAA;IACZ,IAAI,CAAC,EAAE,MAAM,CAAA;IACb,QAAQ,CAAC,EAAE,MAAM,CAAA;IACjB,QAAQ,CAAC,EAAE,MAAM,CAAA;IACjB,QAAQ,CAAC,EAAE,MAAM,CAAA;CAClB;AAQD;;;;;;GAMG;AACH,wBAAgB,eAAe,CAAC,GAAG,EAAE,MAAM,GAAG,SAAS,CAwBtD;AAED;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAkCG;AACH,wBAAgB,mBAAmB,CACjC,KAAK,EAAE,MAAM,EACb,OAAO,EAAE,MAAM,EACf,CAAC,EAAE,SAAS,EACZ,QAAQ,GAAE,MAAM,CAAC,QAA2B,GAC3C,MAAM,CAkCR;AAED;;;;;;;;;;;;;;GAcG;AACH,wBAAgB,cAAc,CAAC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