diff --git a/apps/macos/Sources/Clawdbot/DebugSettings.swift b/apps/macos/Sources/Clawdbot/DebugSettings.swift index 944aafcda..f2675b116 100644 --- a/apps/macos/Sources/Clawdbot/DebugSettings.swift +++ b/apps/macos/Sources/Clawdbot/DebugSettings.swift @@ -28,7 +28,6 @@ struct DebugSettings: View { @State private var tunnelResetInFlight = false @State private var tunnelResetStatus: String? @State private var pendingKill: DebugActions.PortListener? - @AppStorage(attachExistingGatewayOnlyKey) private var attachExistingGatewayOnly: Bool = false @AppStorage(debugFileLogEnabledKey) private var diagnosticsFileLogEnabled: Bool = false @AppStorage(appLogLevelKey) private var appLogLevelRaw: String = AppLogLevel.default.rawValue @@ -145,16 +144,6 @@ struct DebugSettings: View { } .frame(maxWidth: .infinity, alignment: .leading) } - GridRow { - self.gridLabel("Attach only") - Toggle("", isOn: self.$attachExistingGatewayOnly) - .labelsHidden() - .toggleStyle(.checkbox) - .help( - "When enabled in local mode, the mac app will only connect " + - "to an already-running gateway " + - "and will not start one itself.") - } } let key = DeepLinkHandler.currentKey() @@ -782,7 +771,7 @@ struct DebugSettings: View { } private var canRestartGateway: Bool { - self.state.connectionMode == .local && !self.attachExistingGatewayOnly + self.state.connectionMode == .local && !self.state.attachExistingGatewayOnly } private func configURL() -> URL { diff --git a/apps/macos/Sources/Clawdbot/GeneralSettings.swift b/apps/macos/Sources/Clawdbot/GeneralSettings.swift index d4e3476fd..7f5368cb4 100644 --- a/apps/macos/Sources/Clawdbot/GeneralSettings.swift +++ b/apps/macos/Sources/Clawdbot/GeneralSettings.swift @@ -185,6 +185,10 @@ struct GeneralSettings: View { if !self.isNixMode { self.gatewayInstallerCard } + SettingsToggleRow( + title: "Attach only", + subtitle: "Use this when the gateway runs externally; the mac app will only attach to an already-running gateway and won't start one locally.", + binding: self.$state.attachExistingGatewayOnly) TailscaleIntegrationSection( connectionMode: self.state.connectionMode, isPaused: self.state.isPaused)