You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The `diff_opts` configuration allows you to customize diff behavior:
290
290
291
291
-`keep_terminal_focus` (boolean, default: `false`) - When enabled, keeps focus in the Claude Code terminal when a diff opens instead of moving focus to the diff buffer. This allows you to continue using terminal keybindings like `<CR>` for accepting/rejecting diffs without accidentally triggering other mappings.
292
+
-`open_in_new_tab` (boolean, default: `false`) - Open diffs in a new tab instead of the current tab.
293
+
-`hide_terminal_in_new_tab` (boolean, default: `false`) - When opening diffs in a new tab, do not show the Claude terminal split in that new tab. The terminal remains in the original tab, giving maximum screen estate for reviewing the diff.
292
294
293
295
**Example use case**: If you frequently use `<CR>` or arrow keys in the Claude Code terminal to accept/reject diffs, enable this option to prevent focus from moving to the diff buffer where `<CR>` might trigger unintended actions.
294
296
295
297
```lua
296
298
require("claudecode").setup({
297
299
diff_opts= {
298
300
keep_terminal_focus=true, -- If true, moves focus back to terminal after diff opens
301
+
open_in_new_tab=true, -- Open diff in a separate tab
302
+
hide_terminal_in_new_tab=true, -- In the new tab, do not show Claude terminal
0 commit comments