@usepowerplant/cli 0.4.43 → 0.4.45
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/main.js +115 -40
- package/dist/menubar/Powerplant.app.zip +0 -0
- package/package.json +1 -1
package/dist/main.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
|
|
2
|
-
!function(){try{var e="undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof globalThis?globalThis:"undefined"!=typeof self?self:{},n=(new e.Error).stack;n&&(e._sentryDebugIds=e._sentryDebugIds||{},e._sentryDebugIds[n]="
|
|
2
|
+
!function(){try{var e="undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof globalThis?globalThis:"undefined"!=typeof self?self:{},n=(new e.Error).stack;n&&(e._sentryDebugIds=e._sentryDebugIds||{},e._sentryDebugIds[n]="fc35294e-883a-5146-8d1c-99832269672d")}catch(e){}}();
|
|
3
3
|
import { createRequire as __cliCreateRequire } from 'node:module';
|
|
4
4
|
const require = __cliCreateRequire(import.meta.url);
|
|
5
5
|
var __create = Object.create;
|
|
@@ -61367,8 +61367,16 @@ function latest(a, b2) {
|
|
|
61367
61367
|
}
|
|
61368
61368
|
|
|
61369
61369
|
// ../core/src/onboarding.ts
|
|
61370
|
+
var SYNC_WINDOW_MS = 7 * 24 * 60 * 60 * 1e3;
|
|
61370
61371
|
var SAME_HOUR_MS = 60 * 60 * 1e3;
|
|
61371
61372
|
function describeSyncSignals(member, now, noUpload = "no sessions uploaded yet") {
|
|
61373
|
+
return syncSignalsLine(
|
|
61374
|
+
member,
|
|
61375
|
+
now,
|
|
61376
|
+
(age) => age === null ? noUpload : `last uploaded session ${age}`
|
|
61377
|
+
);
|
|
61378
|
+
}
|
|
61379
|
+
function syncSignalsLine(member, now, sessionClause) {
|
|
61372
61380
|
const session = member.lastSessionActivityAt;
|
|
61373
61381
|
const poll = member.lastCheckedInAt;
|
|
61374
61382
|
const error63 = member.lastSyncErrorAt;
|
|
@@ -61376,7 +61384,7 @@ function describeSyncSignals(member, now, noUpload = "no sessions uploaded yet")
|
|
|
61376
61384
|
if (session === null && poll === null && error63 === null) return null;
|
|
61377
61385
|
const age = (at) => describeDataAge(new Date(at), now);
|
|
61378
61386
|
const apart = (a, b2) => b2 === null || Math.abs(Date.parse(a) - Date.parse(b2)) > SAME_HOUR_MS;
|
|
61379
|
-
const parts = [session === null ?
|
|
61387
|
+
const parts = [sessionClause(session === null ? null : age(session))];
|
|
61380
61388
|
if (error63 !== null) parts.push(`reported sync error ${age(error63)}`);
|
|
61381
61389
|
if (paused) parts.push("syncing paused");
|
|
61382
61390
|
const pollSays = error63 !== null ? apart(poll ?? error63, error63) : paused || apart(poll ?? "", session);
|
|
@@ -61520,6 +61528,15 @@ var recentSessionCursorSchema = external_exports.object({
|
|
|
61520
61528
|
id: external_exports.uuid()
|
|
61521
61529
|
});
|
|
61522
61530
|
|
|
61531
|
+
// ../core/src/sessionVisibility.ts
|
|
61532
|
+
var VISIBILITY_LEVELS = ["metadata", "full"];
|
|
61533
|
+
|
|
61534
|
+
// ../core/src/sessionVisibilitySetting.ts
|
|
61535
|
+
var sessionVisibilitySettingSchema = external_exports.enum(VISIBILITY_LEVELS);
|
|
61536
|
+
function describeOwnSessionVisibility(setting) {
|
|
61537
|
+
return setting === "full" ? "Your new sessions share in full with teammates who can read the repo." : "Your new sessions share as metadata.";
|
|
61538
|
+
}
|
|
61539
|
+
|
|
61523
61540
|
// ../../node_modules/.pnpm/@sentry+core@10.78.0/node_modules/@sentry/core/build/esm/debug-build.js
|
|
61524
61541
|
var DEBUG_BUILD = typeof __SENTRY_DEBUG__ === "undefined" || __SENTRY_DEBUG__;
|
|
61525
61542
|
|
|
@@ -88454,7 +88471,7 @@ function _init2(options = {}, getDefaultIntegrationsImpl) {
|
|
|
88454
88471
|
import tls2 from "node:tls";
|
|
88455
88472
|
var import_undici = __toESM(require_undici(), 1);
|
|
88456
88473
|
var CLI_VERSION_HEADER = "x-powerplant-cli-version";
|
|
88457
|
-
var cliVersion = true ? "0.4.
|
|
88474
|
+
var cliVersion = true ? "0.4.45" : "0.0.0-checkout";
|
|
88458
88475
|
function cliVersionHeaders() {
|
|
88459
88476
|
return { [CLI_VERSION_HEADER]: cliVersion, "user-agent": `powerplant-cli/${cliVersion}` };
|
|
88460
88477
|
}
|
|
@@ -94691,6 +94708,7 @@ var POWERPLANT_PUBLISHER = { O: "Forestwalk Labs, Inc.", C: "CA" };
|
|
|
94691
94708
|
var POWERPLANT_WINDOWS_PUBLISHER = false ? null : POWERPLANT_PUBLISHER;
|
|
94692
94709
|
var POWERPLANT_SIGNER = { vendor: "Powerplant", windowsSubject: POWERPLANT_WINDOWS_PUBLISHER };
|
|
94693
94710
|
var REGISTRY_HOST = "registry.npmjs.org";
|
|
94711
|
+
var DOWNLOAD_TIMEOUT_MS = 10 * 6e4;
|
|
94694
94712
|
var MAX_TARBALL_BYTES = 512 * 1024 * 1024;
|
|
94695
94713
|
var releaseAnswerSchema = external_exports.object({
|
|
94696
94714
|
data: external_exports.object({
|
|
@@ -94722,8 +94740,9 @@ async function downloadRelease(release2, file2, fetchImpl = fetch) {
|
|
|
94722
94740
|
}
|
|
94723
94741
|
let response;
|
|
94724
94742
|
try {
|
|
94725
|
-
response = await fetchImpl(url2, { signal: AbortSignal.timeout(
|
|
94743
|
+
response = await fetchImpl(url2, { signal: AbortSignal.timeout(DOWNLOAD_TIMEOUT_MS), redirect: "error" });
|
|
94726
94744
|
} catch (error63) {
|
|
94745
|
+
if (isTimeout(error63)) throw downloadTimedOut(release2, error63);
|
|
94727
94746
|
throw new ExpectedCliError(`Could not download Powerplant ${release2.version} (${error63 instanceof Error ? error63.message : String(error63)}).`);
|
|
94728
94747
|
}
|
|
94729
94748
|
if (!response.ok || response.body === null) {
|
|
@@ -94750,9 +94769,19 @@ async function downloadRelease(release2, file2, fetchImpl = fetch) {
|
|
|
94750
94769
|
}
|
|
94751
94770
|
} catch (error63) {
|
|
94752
94771
|
rmSync8(file2, { force: true });
|
|
94772
|
+
if (isTimeout(error63)) throw downloadTimedOut(release2, error63);
|
|
94753
94773
|
throw error63;
|
|
94754
94774
|
}
|
|
94755
94775
|
}
|
|
94776
|
+
function isTimeout(error63) {
|
|
94777
|
+
return error63 instanceof DOMException && error63.name === "TimeoutError";
|
|
94778
|
+
}
|
|
94779
|
+
function downloadTimedOut(release2, cause) {
|
|
94780
|
+
return new ExpectedCliError(
|
|
94781
|
+
`The download of Powerplant ${release2.version} did not finish within ${DOWNLOAD_TIMEOUT_MS / 6e4} minutes. Check this computer's internet connection, then try again.`,
|
|
94782
|
+
{ cause }
|
|
94783
|
+
);
|
|
94784
|
+
}
|
|
94756
94785
|
function unpackWindowsTarball(file2, folder, tar) {
|
|
94757
94786
|
mkdirSync11(folder, { recursive: true });
|
|
94758
94787
|
const result = spawnSync5(tar, ["-xzf", file2, "-C", folder, "--strip-components=1"], {
|
|
@@ -95000,15 +95029,23 @@ var updateProgressSchema = external_exports.object({
|
|
|
95000
95029
|
finishedAt: external_exports.string().optional(),
|
|
95001
95030
|
/** One line of why, for a failure. */
|
|
95002
95031
|
detail: external_exports.string().optional(),
|
|
95003
|
-
/**
|
|
95004
|
-
*
|
|
95005
|
-
*
|
|
95006
|
-
cause: external_exports.enum(["release-not-served"]).optional(),
|
|
95007
|
-
/** Failed installs of this target so far: on a failed record including
|
|
95008
|
-
* this one, on a reservation the count the retry continues from. */
|
|
95032
|
+
/** Failed installs of this target in a row: on a failed record including
|
|
95033
|
+
* this one, on an installing record the count this run continues from.
|
|
95034
|
+
* The hourly update reads it to space out its retries. */
|
|
95009
95035
|
attempts: external_exports.number().int().nonnegative().optional()
|
|
95010
95036
|
});
|
|
95011
95037
|
var UPDATE_PROGRESS_STALE_MS = 15 * 6e4;
|
|
95038
|
+
function failedAttemptsAt(progress, target, now) {
|
|
95039
|
+
if (progress === null || progress.target !== target) return 0;
|
|
95040
|
+
switch (progress.state) {
|
|
95041
|
+
case "up-to-date":
|
|
95042
|
+
return 0;
|
|
95043
|
+
case "failed":
|
|
95044
|
+
return progress.attempts ?? 1;
|
|
95045
|
+
case "installing":
|
|
95046
|
+
return (progress.attempts ?? 0) + (now - Date.parse(progress.startedAt) > UPDATE_PROGRESS_STALE_MS ? 1 : 0);
|
|
95047
|
+
}
|
|
95048
|
+
}
|
|
95012
95049
|
function updateProgressPath(homeDir) {
|
|
95013
95050
|
return path30.join(collectorStateDir(homeDir), "cli-update.json");
|
|
95014
95051
|
}
|
|
@@ -95225,7 +95262,11 @@ function startNewCopy(output2) {
|
|
|
95225
95262
|
}
|
|
95226
95263
|
async function runInstalledUpdate(run2) {
|
|
95227
95264
|
const startedAt = new Date(run2.now()).toISOString();
|
|
95228
|
-
const
|
|
95265
|
+
const previous = run2.progress.read();
|
|
95266
|
+
const write2 = (state, target2, extra = {}) => {
|
|
95267
|
+
const attempts = failedAttemptsAt(previous, target2, Date.parse(startedAt)) + (state === "failed" ? 1 : 0);
|
|
95268
|
+
run2.progress.write({ state, target: target2, startedAt, pid: run2.pid, ...attempts > 0 && state !== "up-to-date" && { attempts }, ...extra });
|
|
95269
|
+
};
|
|
95229
95270
|
let target = run2.target;
|
|
95230
95271
|
write2("installing", target);
|
|
95231
95272
|
mkdirSync15(run2.workFolder, { recursive: true });
|
|
@@ -105493,6 +105534,9 @@ function ago(ms) {
|
|
|
105493
105534
|
return ms < 6e4 ? "just now" : `${duration3(ms)} ago`;
|
|
105494
105535
|
}
|
|
105495
105536
|
|
|
105537
|
+
// src/update.ts
|
|
105538
|
+
import path61 from "node:path";
|
|
105539
|
+
|
|
105496
105540
|
// src/installOwner.ts
|
|
105497
105541
|
import { accessSync as accessSync3, constants as constants6, readFileSync as readFileSync27 } from "node:fs";
|
|
105498
105542
|
import path60 from "node:path";
|
|
@@ -105613,8 +105657,9 @@ function realInspectEnvironment() {
|
|
|
105613
105657
|
}
|
|
105614
105658
|
|
|
105615
105659
|
// src/update.ts
|
|
105616
|
-
|
|
105617
|
-
var
|
|
105660
|
+
var HOURLY_RETRY_ATTEMPTS = 3;
|
|
105661
|
+
var HOURLY_RETRY_WAIT_MS = 50 * 6e4;
|
|
105662
|
+
var DAILY_RETRY_MS = 24 * 60 * 6e4;
|
|
105618
105663
|
function releaseNotServed(managerOutput) {
|
|
105619
105664
|
return /\bETARGET\b|\bnotarget\b|ERR_PNPM_NO_MATCHING_VERSION/.test(managerOutput);
|
|
105620
105665
|
}
|
|
@@ -105628,12 +105673,14 @@ function updateProgressView(progress, cliVersion2, now) {
|
|
|
105628
105673
|
if (progress === null || progress.state === "up-to-date") return { kind: "none" };
|
|
105629
105674
|
const reached = progress.target === null ? null : compareReleaseVersions(cliVersion2, progress.target);
|
|
105630
105675
|
if (reached === 0 || reached === 1) return { kind: "none" };
|
|
105676
|
+
const startedAt = Date.parse(progress.startedAt);
|
|
105677
|
+
const attempts = failedAttemptsAt(progress, progress.target, now);
|
|
105678
|
+
const retryAt = startedAt + (attempts < HOURLY_RETRY_ATTEMPTS ? HOURLY_RETRY_WAIT_MS : DAILY_RETRY_MS);
|
|
105631
105679
|
if (progress.state === "failed") {
|
|
105632
|
-
|
|
105633
|
-
return { kind: "failed", target: progress.target, detail: progress.detail ?? "It didn't finish.", retryable };
|
|
105680
|
+
return { kind: "failed", target: progress.target, detail: progress.detail ?? "It didn't finish.", retryAt };
|
|
105634
105681
|
}
|
|
105635
|
-
if (now -
|
|
105636
|
-
return { kind: "failed", target: progress.target, detail: "It didn't finish within 15 minutes.",
|
|
105682
|
+
if (now - startedAt > UPDATE_PROGRESS_STALE_MS) {
|
|
105683
|
+
return { kind: "failed", target: progress.target, detail: "It didn't finish within 15 minutes.", retryAt };
|
|
105637
105684
|
}
|
|
105638
105685
|
return { kind: "installing", target: progress.target };
|
|
105639
105686
|
}
|
|
@@ -105657,7 +105704,8 @@ async function runUpdate(deps) {
|
|
|
105657
105704
|
}
|
|
105658
105705
|
const startedAt = new Date(deps.now()).toISOString();
|
|
105659
105706
|
const reserved = running?.state === "installing" ? running.target : null;
|
|
105660
|
-
const
|
|
105707
|
+
const priorFailures = (release2) => failedAttemptsAt(running, release2, Date.parse(startedAt));
|
|
105708
|
+
const attempts = (release2) => priorFailures(release2) > 0 ? { attempts: priorFailures(release2) } : {};
|
|
105661
105709
|
deps.writeProgress({ state: "installing", target: reserved, startedAt, pid: deps.pid, ...attempts(reserved) });
|
|
105662
105710
|
const resolved = await deps.resolveTarget();
|
|
105663
105711
|
if (resolved !== null) deps.recordAvailableVersion(resolved);
|
|
@@ -105697,8 +105745,7 @@ async function runUpdate(deps) {
|
|
|
105697
105745
|
pid: deps.pid,
|
|
105698
105746
|
finishedAt: new Date(deps.now()).toISOString(),
|
|
105699
105747
|
detail,
|
|
105700
|
-
|
|
105701
|
-
attempts: (attempts(target).attempts ?? 0) + 1
|
|
105748
|
+
attempts: priorFailures(target) + 1
|
|
105702
105749
|
});
|
|
105703
105750
|
throw new ExpectedCliError(`${detail} A release can take a few minutes to appear; try again shortly, or update by hand: ${byHand}`);
|
|
105704
105751
|
}
|
|
@@ -105710,7 +105757,8 @@ async function runUpdate(deps) {
|
|
|
105710
105757
|
startedAt,
|
|
105711
105758
|
pid: deps.pid,
|
|
105712
105759
|
finishedAt: new Date(deps.now()).toISOString(),
|
|
105713
|
-
detail
|
|
105760
|
+
detail,
|
|
105761
|
+
attempts: priorFailures(target) + 1
|
|
105714
105762
|
});
|
|
105715
105763
|
throw new ExpectedCliError(`${detail}. Update by hand: ${byHand}`);
|
|
105716
105764
|
}
|
|
@@ -105723,7 +105771,8 @@ async function runUpdate(deps) {
|
|
|
105723
105771
|
startedAt,
|
|
105724
105772
|
pid: deps.pid,
|
|
105725
105773
|
finishedAt: new Date(deps.now()).toISOString(),
|
|
105726
|
-
detail
|
|
105774
|
+
detail,
|
|
105775
|
+
attempts: priorFailures(target) + 1
|
|
105727
105776
|
});
|
|
105728
105777
|
throw new ExpectedCliError(`${detail}. Update by hand: ${byHand}`);
|
|
105729
105778
|
}
|
|
@@ -105747,8 +105796,8 @@ function launchBackgroundUpdate(deps) {
|
|
|
105747
105796
|
return "already-running";
|
|
105748
105797
|
}
|
|
105749
105798
|
const startedAt = new Date(deps.now()).toISOString();
|
|
105750
|
-
const attempts = running
|
|
105751
|
-
deps.writeProgress({ state: "installing", target: deps.target, startedAt, pid: null, ...attempts
|
|
105799
|
+
const attempts = failedAttemptsAt(running, deps.target, deps.now());
|
|
105800
|
+
deps.writeProgress({ state: "installing", target: deps.target, startedAt, pid: null, ...attempts > 0 && { attempts } });
|
|
105752
105801
|
if (deps.spawnChild() === void 0) {
|
|
105753
105802
|
deps.writeProgress({
|
|
105754
105803
|
state: "failed",
|
|
@@ -105756,7 +105805,8 @@ function launchBackgroundUpdate(deps) {
|
|
|
105756
105805
|
startedAt,
|
|
105757
105806
|
pid: null,
|
|
105758
105807
|
finishedAt: new Date(deps.now()).toISOString(),
|
|
105759
|
-
detail: "The background update could not start."
|
|
105808
|
+
detail: "The background update could not start.",
|
|
105809
|
+
attempts: attempts + 1
|
|
105760
105810
|
});
|
|
105761
105811
|
throw new ExpectedCliError("Could not start the background update.");
|
|
105762
105812
|
}
|
|
@@ -105818,6 +105868,9 @@ function parseAutomaticFlag(value) {
|
|
|
105818
105868
|
function setAutomaticUpdates(appEnv, enabled) {
|
|
105819
105869
|
updateCollectorControl(appEnv, (control) => ({ ...control, autoUpdate: enabled }));
|
|
105820
105870
|
}
|
|
105871
|
+
function failureHoldsRelease(failed2, latestVersion) {
|
|
105872
|
+
return failed2.target === null || failed2.target === latestVersion;
|
|
105873
|
+
}
|
|
105821
105874
|
function autoUpdateDecision(i) {
|
|
105822
105875
|
if (!automaticUpdatesOn(i.control)) return { kind: "skip", reason: "off" };
|
|
105823
105876
|
if (!i.inspection.inPlace.ok) {
|
|
@@ -105827,10 +105880,8 @@ function autoUpdateDecision(i) {
|
|
|
105827
105880
|
if (!isUpdateAvailable(i.cliVersion, i.latestVersion)) return { kind: "skip", reason: "up-to-date" };
|
|
105828
105881
|
const progress = updateProgressView(i.progress, i.cliVersion, i.now);
|
|
105829
105882
|
if (progress.kind === "installing") return { kind: "skip", reason: "already-running" };
|
|
105830
|
-
|
|
105831
|
-
|
|
105832
|
-
if (progress.retryable) return { kind: "update", target: i.latestVersion };
|
|
105833
|
-
return { kind: "skip", reason: "failed-before", detail: progress.detail };
|
|
105883
|
+
if (progress.kind === "failed" && failureHoldsRelease(progress, i.latestVersion) && i.now < progress.retryAt) {
|
|
105884
|
+
return { kind: "skip", reason: "retry-later", detail: progress.detail };
|
|
105834
105885
|
}
|
|
105835
105886
|
return { kind: "update", target: i.latestVersion };
|
|
105836
105887
|
}
|
|
@@ -106015,10 +106066,10 @@ function updateItems(i, progress, envArgs2, problem) {
|
|
|
106015
106066
|
}
|
|
106016
106067
|
}
|
|
106017
106068
|
function failedUpdateDetail(i, progress) {
|
|
106018
|
-
if (
|
|
106019
|
-
|
|
106020
|
-
|
|
106021
|
-
return
|
|
106069
|
+
if (!automaticUpdatesOn(i.control) || i.service !== "loaded" || !i.update.inPlace) return progress.detail;
|
|
106070
|
+
const sentence = /[.!?]$/.test(progress.detail) ? progress.detail : `${progress.detail}.`;
|
|
106071
|
+
const waitsADay = failureHoldsRelease(progress, i.latestVersion) && progress.retryAt - i.now > 60 * 6e4;
|
|
106072
|
+
return `${sentence} Background sync retries ${waitsADay ? "in about a day" : "within the hour"}.`;
|
|
106022
106073
|
}
|
|
106023
106074
|
function collectorBlock(i, envArgs2, problem, warning2, more) {
|
|
106024
106075
|
const restart = {
|
|
@@ -107426,7 +107477,7 @@ async function confirmResume(deps, output2) {
|
|
|
107426
107477
|
var MACOS_BLOCKED_FOLDER_REMEDY = "To allow it, open System Settings > Privacy & Security > Files and Folders, enable the folder for node, then run `powerplant init`.";
|
|
107427
107478
|
|
|
107428
107479
|
// src/version.ts
|
|
107429
|
-
var CLI_VERSION = true ? "0.4.
|
|
107480
|
+
var CLI_VERSION = true ? "0.4.45" : "0.0.0-checkout";
|
|
107430
107481
|
var CLI_RELEASE_BUILD = true ? true : false;
|
|
107431
107482
|
var CLI_DEVELOPMENT_COPY = false;
|
|
107432
107483
|
function updateRefusal(tarball, developmentCopy = CLI_DEVELOPMENT_COPY) {
|
|
@@ -107542,6 +107593,7 @@ function machineBlock(i, syncing) {
|
|
|
107542
107593
|
);
|
|
107543
107594
|
details.push(signals ?? "No sync has run since background sync started.");
|
|
107544
107595
|
}
|
|
107596
|
+
if (i.sessionVisibility) details.push(i.sessionVisibility.line);
|
|
107545
107597
|
return [block(line, ...details)];
|
|
107546
107598
|
}
|
|
107547
107599
|
function warnings(i) {
|
|
@@ -107655,7 +107707,8 @@ function statusJson(i) {
|
|
|
107655
107707
|
automaticUpdates: automaticUpdatesChoice(i.control),
|
|
107656
107708
|
pausedAt: i.control.pausedAt ?? null,
|
|
107657
107709
|
// The same saved checks the human rendering reads, each with when it ran.
|
|
107658
|
-
mcpConnections: i.connections
|
|
107710
|
+
mcpConnections: i.connections,
|
|
107711
|
+
sessionVisibility: i.sessionVisibility ?? null
|
|
107659
107712
|
};
|
|
107660
107713
|
}
|
|
107661
107714
|
function supportedFlag(cliVersion2, oldestSupportedVersion) {
|
|
@@ -108176,6 +108229,26 @@ function runResumeSession(source, sessionId, deps = {}) {
|
|
|
108176
108229
|
}
|
|
108177
108230
|
}
|
|
108178
108231
|
|
|
108232
|
+
// src/sessionVisibilityLine.ts
|
|
108233
|
+
var FETCH_TIMEOUT_MS2 = 3e3;
|
|
108234
|
+
var workspacesAnswer = external_exports.object({
|
|
108235
|
+
data: external_exports.object({ sessionVisibility: sessionVisibilitySettingSchema.optional().catch(void 0) })
|
|
108236
|
+
});
|
|
108237
|
+
async function readSessionVisibilityLine(credentials, fetchImpl = fetch) {
|
|
108238
|
+
if (credentials === null) return null;
|
|
108239
|
+
try {
|
|
108240
|
+
const response = await fetchImpl(`${credentials.apiUrl}/api/collector/workspaces`, {
|
|
108241
|
+
headers: { authorization: `Bearer ${credentials.token}`, ...cliVersionHeaders() },
|
|
108242
|
+
signal: AbortSignal.timeout(FETCH_TIMEOUT_MS2)
|
|
108243
|
+
});
|
|
108244
|
+
if (!response.ok) return null;
|
|
108245
|
+
const setting = workspacesAnswer.safeParse(await response.json()).data?.data.sessionVisibility;
|
|
108246
|
+
return setting === void 0 ? null : { setting, line: describeOwnSessionVisibility(setting) };
|
|
108247
|
+
} catch {
|
|
108248
|
+
return null;
|
|
108249
|
+
}
|
|
108250
|
+
}
|
|
108251
|
+
|
|
108179
108252
|
// src/installProgress.ts
|
|
108180
108253
|
function installProgress(writer, update) {
|
|
108181
108254
|
const show = () => update ? () => {
|
|
@@ -108638,7 +108711,7 @@ var workspaceSchema = external_exports.object({
|
|
|
108638
108711
|
role: external_exports.string().min(1),
|
|
108639
108712
|
active: external_exports.boolean()
|
|
108640
108713
|
});
|
|
108641
|
-
var
|
|
108714
|
+
var FETCH_TIMEOUT_MS3 = 1e4;
|
|
108642
108715
|
async function callApi(credentials, path70, init3, fetchImpl) {
|
|
108643
108716
|
let response;
|
|
108644
108717
|
try {
|
|
@@ -108649,7 +108722,7 @@ async function callApi(credentials, path70, init3, fetchImpl) {
|
|
|
108649
108722
|
"content-type": "application/json",
|
|
108650
108723
|
...cliVersionHeaders()
|
|
108651
108724
|
},
|
|
108652
|
-
signal: AbortSignal.timeout(
|
|
108725
|
+
signal: AbortSignal.timeout(FETCH_TIMEOUT_MS3)
|
|
108653
108726
|
});
|
|
108654
108727
|
} catch (error63) {
|
|
108655
108728
|
const detail = error63 instanceof Error ? error63.message : String(error63);
|
|
@@ -109192,8 +109265,9 @@ The access you granted these agents stays on your Powerplant account until you r
|
|
|
109192
109265
|
const service2 = readServiceSafelyAsync(copy.service);
|
|
109193
109266
|
const stored = loadCredentialsSafely(config2);
|
|
109194
109267
|
const credentials = stored.credentials;
|
|
109195
|
-
const [[latestVersion, oldestSupportedVersion], protectedSessions, serviceRead, moving] = await Promise.all([
|
|
109268
|
+
const [[latestVersion, oldestSupportedVersion], sessionVisibility, protectedSessions, serviceRead, moving] = await Promise.all([
|
|
109196
109269
|
fetchVersionFacts(config2.appEnv, credentials, CLI_PACKAGE_NAME),
|
|
109270
|
+
readSessionVisibilityLine(credentials),
|
|
109197
109271
|
process.platform === "darwin" && credentials ? findRecentProtectedSessions({
|
|
109198
109272
|
environment: { allowedProtectedRoots: credentials.repoDiscoveryRoots ?? [] }
|
|
109199
109273
|
}).then(
|
|
@@ -109202,7 +109276,7 @@ The access you granted these agents stays on your Powerplant account until you r
|
|
|
109202
109276
|
service2,
|
|
109203
109277
|
moveToInstalledCopy(config2, copy)
|
|
109204
109278
|
]);
|
|
109205
|
-
return { stored, latestVersion, oldestSupportedVersion, protectedSessions, serviceRead, moving };
|
|
109279
|
+
return { stored, latestVersion, oldestSupportedVersion, sessionVisibility, protectedSessions, serviceRead, moving };
|
|
109206
109280
|
};
|
|
109207
109281
|
const found = values.json ? await read2() : await terminal.command.activity("Checking sync status\u2026", read2);
|
|
109208
109282
|
const inputs = {
|
|
@@ -109217,6 +109291,7 @@ The access you granted these agents stays on your Powerplant account until you r
|
|
|
109217
109291
|
oldestSupportedVersion: found.oldestSupportedVersion,
|
|
109218
109292
|
protectedSessions: found.protectedSessions,
|
|
109219
109293
|
moveToInstalledCopy: found.moving,
|
|
109294
|
+
sessionVisibility: found.sessionVisibility,
|
|
109220
109295
|
connections: readHarnessConnections(config2.appEnv, realReadTextFile),
|
|
109221
109296
|
...readMcpPreferencesForMenu(config2.appEnv),
|
|
109222
109297
|
now: Date.now()
|
|
@@ -109814,4 +109889,4 @@ undici/lib/web/websocket/frame.js:
|
|
|
109814
109889
|
(*! ws. MIT License. Einar Otto Stangvik <einaros@gmail.com> *)
|
|
109815
109890
|
*/
|
|
109816
109891
|
|
|
109817
|
-
//# debugId=
|
|
109892
|
+
//# debugId=fc35294e-883a-5146-8d1c-99832269672d
|
|
Binary file
|