diff --git a/src/extension.ts b/src/extension.ts index aaf2731..517ce1e 100644 --- a/src/extension.ts +++ b/src/extension.ts @@ -2637,6 +2637,12 @@ class ClaudeChatProvider { } private _executeSlashCommand(command: string): void { + // Handle /compact in chat instead of spawning a terminal + if (command === 'compact') { + this._sendMessageToClaude(`/${command}`); + return; + } + const config = vscode.workspace.getConfiguration('claudeCodeChat'); const wslEnabled = config.get('wsl.enabled', false); const wslDistro = config.get('wsl.distro', 'Ubuntu'); diff --git a/src/script.ts b/src/script.ts index 2d34c42..ba846da 100644 --- a/src/script.ts +++ b/src/script.ts @@ -1679,18 +1679,22 @@ const getScript = (isTelemetryEnabled: boolean) => `