@devries-cameron20 / t3code Mirror · read-only / commits / 57ec00ddd6
Fork 0

The best way to control Claude Code, Codex and more from any computer or phone

Mirrored from https://github.com/Camo67/t3code.git

Synced Nov 21, 09:45 UTC

fix(web): source control settings notice a CLI login made outside the app (#37509)

Julius Marminge committed Nov 15, 2026 at 22:03 UTC 57ec00ddd64f5ae413d533bc503b06b49e2f8232
1 file changed +13
apps/web/src/components/settings/SourceControlSettings.tsx
+13
@@ -12,6 +12,7 @@ import type {
12 } from "@t3tools/contracts";
13 import { useSettingsScope } from "./SettingsScopeContext";
14 import { ProjectDefaultsSettings } from "./ProjectDefaultsSettings";
15 +import { useLiveRefresh } from "../../hooks/useLiveRefresh";
16 import { cn } from "../../lib/utils";
17 import { useEnvironmentQuery } from "../../state/query";
18 import { serverEnvironment } from "../../state/server";
@@ -414,6 +415,18 @@ export function SourceControlSettingsPanel() {
415 const handleScan = () => {
416 discovery.refresh();
417 };
418 + // A CLI login on the server host changes nothing the client reads, so returning to the window
419 + // asks again. Discovery runs every hosting CLI, too costly for a timer nobody asked for.
420 + useLiveRefresh(
421 + () => {
422 + if (!discovery.isPending) discovery.refresh();
423 + },
424 + {
425 + enabled: environmentId !== null,
426 + key: `source-control-discovery:${environmentId}`,
427 + intervalMs: null,
428 + },
429 + );
430 const offeredProviders = environment?.serverConfig?.settings.offeredSourceControlProviders;
431 const updateSettings = useAtomCommand(serverEnvironment.updateSettings, {
432 label: "save source control providers",