From ff11ba03090f95aec6312302596ca3c380c7982b Mon Sep 17 00:00:00 2001 From: Lawrence Chen <54008264+lawrencecchen@users.noreply.github.com> Date: Sat, 21 Feb 2026 04:31:00 -0800 Subject: [PATCH] Enable Claude Code integration by default (#247) --- Sources/cmuxApp.swift | 2 +- cmuxTests/GhosttyConfigTests.swift | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/Sources/cmuxApp.swift b/Sources/cmuxApp.swift index 48ec051c..3f5a72a8 100644 --- a/Sources/cmuxApp.swift +++ b/Sources/cmuxApp.swift @@ -2418,7 +2418,7 @@ enum AppearanceSettings { enum ClaudeCodeIntegrationSettings { static let hooksEnabledKey = "claudeCodeHooksEnabled" - static let defaultHooksEnabled = false + static let defaultHooksEnabled = true static func hooksEnabled(defaults: UserDefaults = .standard) -> Bool { if defaults.object(forKey: hooksEnabledKey) == nil { diff --git a/cmuxTests/GhosttyConfigTests.swift b/cmuxTests/GhosttyConfigTests.swift index 386c7131..5f80a466 100644 --- a/cmuxTests/GhosttyConfigTests.swift +++ b/cmuxTests/GhosttyConfigTests.swift @@ -162,7 +162,7 @@ final class GhosttyConfigTests: XCTestCase { ) } - func testClaudeCodeIntegrationDefaultsToDisabledWhenUnset() { + func testClaudeCodeIntegrationDefaultsToEnabledWhenUnset() { let suiteName = "cmux.tests.claude-hooks.\(UUID().uuidString)" guard let defaults = UserDefaults(suiteName: suiteName) else { XCTFail("Failed to create isolated user defaults suite") @@ -173,7 +173,7 @@ final class GhosttyConfigTests: XCTestCase { } defaults.removeObject(forKey: ClaudeCodeIntegrationSettings.hooksEnabledKey) - XCTAssertFalse(ClaudeCodeIntegrationSettings.hooksEnabled(defaults: defaults)) + XCTAssertTrue(ClaudeCodeIntegrationSettings.hooksEnabled(defaults: defaults)) } func testClaudeCodeIntegrationRespectsStoredPreference() {