Skip to content

Commit da08865

Browse files
authored
Merge branch 'main' into feat/shared-terminal
2 parents 24fa2a1 + 11cb88e commit da08865

98 files changed

Lines changed: 1419 additions & 1479 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

‎.github/workflows/ci.yml‎

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -45,6 +45,10 @@ jobs:
4545
- name: Ensure Electron runtime is installed
4646
run: vp run --filter @t3tools/desktop ensure:electron
4747

48+
# Export cleanup is still a manual audit; files and dependencies have no baseline.
49+
- name: Check unused files and dependencies
50+
run: vp run knip:check
51+
4852
- name: Check
4953
run: vp check
5054

‎apps/desktop/src/electron/ElectronDialog.test.ts‎

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -43,7 +43,6 @@ describe("ElectronDialog", () => {
4343
);
4444

4545
assert.instanceOf(error, ElectronDialog.ElectronDialogPickFolderError);
46-
assert.isTrue(ElectronDialog.isElectronDialogError(error));
4746
assert.strictEqual(error.ownerWindowId, 7);
4847
assert.strictEqual(error.defaultPath, "/workspace");
4948
assert.strictEqual(error.cause, cause);

‎apps/desktop/src/electron/ElectronDialog.ts‎

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -73,7 +73,6 @@ export const ElectronDialogError = Schema.Union([
7373
ElectronDialogShowErrorBoxError,
7474
]);
7575
export type ElectronDialogError = typeof ElectronDialogError.Type;
76-
export const isElectronDialogError = Schema.is(ElectronDialogError);
7776

7877
export interface ElectronDialogPickFolderInput {
7978
readonly owner: Option.Option<Electron.BrowserWindow>;

‎apps/desktop/src/electron/ElectronTheme.test.ts‎

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -64,7 +64,6 @@ describe("ElectronTheme", () => {
6464
const error = yield* Effect.flip(electronTheme.setSource("dark"));
6565

6666
assert.instanceOf(error, ElectronTheme.ElectronThemeSetSourceError);
67-
assert.isTrue(ElectronTheme.isElectronThemeSetSourceError(error));
6867
assert.strictEqual(error.source, "dark");
6968
assert.strictEqual(error.cause, cause);
7069
assert.include(error.message, "dark");

‎apps/desktop/src/electron/ElectronTheme.ts‎

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -19,8 +19,6 @@ export class ElectronThemeSetSourceError extends Schema.TaggedErrorClass<Electro
1919
}
2020
}
2121

22-
export const isElectronThemeSetSourceError = Schema.is(ElectronThemeSetSourceError);
23-
2422
export class ElectronTheme extends Context.Service<
2523
ElectronTheme,
2624
{

‎apps/desktop/src/electron/ElectronUpdater.test.ts‎

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -71,7 +71,6 @@ describe("ElectronUpdater", () => {
7171
const error = yield* updater.checkForUpdates.pipe(Effect.flip);
7272

7373
assert.instanceOf(error, ElectronUpdater.ElectronUpdaterCheckForUpdatesError);
74-
assert.isTrue(ElectronUpdater.isElectronUpdaterError(error));
7574
assert.equal(error.channel, "beta");
7675
assert.strictEqual(error.cause, cause);
7776
assert.equal(error.message, "Electron updater failed to check for updates on channel beta.");
@@ -89,7 +88,6 @@ describe("ElectronUpdater", () => {
8988
const error = yield* updater.downloadUpdate.pipe(Effect.flip);
9089

9190
assert.instanceOf(error, ElectronUpdater.ElectronUpdaterDownloadUpdateError);
92-
assert.isTrue(ElectronUpdater.isElectronUpdaterError(error));
9391
assert.equal(error.channel, "nightly");
9492
assert.strictEqual(error.cause, cause);
9593
assert.equal(
@@ -126,7 +124,6 @@ describe("ElectronUpdater", () => {
126124
.pipe(Effect.flip);
127125

128126
assert.instanceOf(error, ElectronUpdater.ElectronUpdaterQuitAndInstallError);
129-
assert.isTrue(ElectronUpdater.isElectronUpdaterError(error));
130127
assert.equal(error.channel, "alpha");
131128
assert.equal(error.isSilent, true);
132129
assert.equal(error.isForceRunAfter, false);

‎apps/desktop/src/electron/ElectronUpdater.ts‎

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -54,7 +54,6 @@ export const ElectronUpdaterError = Schema.Union([
5454
ElectronUpdaterQuitAndInstallError,
5555
]);
5656
export type ElectronUpdaterError = typeof ElectronUpdaterError.Type;
57-
export const isElectronUpdaterError = Schema.is(ElectronUpdaterError);
5857

5958
export class ElectronUpdater extends Context.Service<
6059
ElectronUpdater,

‎apps/desktop/src/electron/ElectronWindow.test.ts‎

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -79,7 +79,6 @@ describe("ElectronWindow", () => {
7979
const error = yield* electronWindow.create(options).pipe(Effect.flip);
8080

8181
assert.instanceOf(error, ElectronWindow.ElectronWindowCreateError);
82-
assert.isTrue(ElectronWindow.isElectronWindowCreateError(error));
8382
assert.deepEqual(error.options, {
8483
title: "T3 Code",
8584
width: 1100,

‎apps/desktop/src/electron/ElectronWindow.ts‎

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -58,8 +58,6 @@ export class ElectronWindowCreateError extends Schema.TaggedErrorClass<ElectronW
5858
}
5959
}
6060

61-
export const isElectronWindowCreateError = Schema.is(ElectronWindowCreateError);
62-
6361
export class ElectronWindowOperationError extends Schema.TaggedErrorClass<ElectronWindowOperationError>()(
6462
"ElectronWindowOperationError",
6563
{

‎apps/desktop/src/linuxSecretStorage.test.ts‎

Lines changed: 0 additions & 77 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,6 @@ import { describe, expect, it } from "vite-plus/test";
33
import {
44
normalizeLinuxPasswordStorePreference,
55
resolveLinuxPasswordStoreSwitch,
6-
resolveLinuxSecretStorageUnavailableMessage,
76
} from "./linuxSecretStorage.ts";
87

98
const autoSwitch = (env: NodeJS.ProcessEnv) =>
@@ -124,80 +123,4 @@ describe("linuxSecretStorage", () => {
124123
}),
125124
).toBe("gnome-libsecret");
126125
});
127-
128-
it("uses GNOME Keyring remediation for libsecret and unknown backends", () => {
129-
expect(
130-
resolveLinuxSecretStorageUnavailableMessage({
131-
configuredPreference: "auto",
132-
selectedBackend: "gnome_libsecret",
133-
env: { XDG_CURRENT_DESKTOP: "niri" },
134-
}),
135-
).toContain("GNOME Keyring");
136-
});
137-
138-
it("prefers explicit libsecret selection over KDE desktop heuristics", () => {
139-
expect(
140-
resolveLinuxSecretStorageUnavailableMessage({
141-
configuredPreference: "gnome-libsecret",
142-
selectedBackend: "unknown",
143-
env: { XDG_CURRENT_DESKTOP: "KDE" },
144-
}),
145-
).toContain("GNOME Keyring");
146-
expect(
147-
resolveLinuxSecretStorageUnavailableMessage({
148-
configuredPreference: "auto",
149-
selectedBackend: "gnome_libsecret",
150-
env: { XDG_CURRENT_DESKTOP: "KDE" },
151-
}),
152-
).toContain("GNOME Keyring");
153-
});
154-
155-
it("prefers explicit KWallet preference over selected gnome-libsecret backend", () => {
156-
expect(
157-
resolveLinuxSecretStorageUnavailableMessage({
158-
configuredPreference: "kwallet6",
159-
selectedBackend: "gnome_libsecret",
160-
env: { XDG_CURRENT_DESKTOP: "niri" },
161-
}),
162-
).toContain("KWallet");
163-
expect(
164-
resolveLinuxSecretStorageUnavailableMessage({
165-
configuredPreference: "kwallet",
166-
selectedBackend: "gnome-libsecret",
167-
env: {},
168-
}),
169-
).toContain("KWallet");
170-
});
171-
172-
it("uses KWallet remediation wording for KDE-looking sessions", () => {
173-
expect(
174-
resolveLinuxSecretStorageUnavailableMessage({
175-
configuredPreference: "auto",
176-
selectedBackend: "kwallet6",
177-
env: {},
178-
}),
179-
).toContain("KWallet");
180-
expect(
181-
resolveLinuxSecretStorageUnavailableMessage({
182-
configuredPreference: "auto",
183-
selectedBackend: "unknown",
184-
env: { XDG_CURRENT_DESKTOP: "KDE" },
185-
}),
186-
).toContain("KWallet");
187-
expect(
188-
resolveLinuxSecretStorageUnavailableMessage({
189-
configuredPreference: "auto",
190-
selectedBackend: "unknown",
191-
env: { DESKTOP_SESSION: "plasmawayland" },
192-
}),
193-
).toContain("KWallet");
194-
// A desktop name outranks a bare KDE marker when choosing the wording.
195-
expect(
196-
resolveLinuxSecretStorageUnavailableMessage({
197-
configuredPreference: "auto",
198-
selectedBackend: "unknown",
199-
env: { GDMSESSION: "gnome", KDE_FULL_SESSION: "true" },
200-
}),
201-
).toContain("GNOME Keyring");
202-
});
203126
});

0 commit comments

Comments
 (0)