Skip to content

Commit b93cc93

Browse files
committed
docs: add note for on_unsaved_changes discard behavior
1 parent bfb9a4d commit b93cc93

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -273,7 +273,7 @@ For deep technical details, see [ARCHITECTURE.md](./ARCHITECTURE.md).
273273
vertical_split = true,
274274
open_in_current_tab = true,
275275
keep_terminal_focus = false, -- If true, moves focus back to terminal after diff opens
276-
on_unsaved_changes = "error" -- "error" or "discard"
276+
on_unsaved_changes = "error" -- "error" or "discard" (discard uses :edit! to reload the file and will lose unsaved changes)
277277
},
278278
},
279279
keys = {

lua/claudecode/config.lua

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ M.defaults = {
2424
vertical_split = true,
2525
open_in_current_tab = true, -- Use current tab instead of creating new tab
2626
keep_terminal_focus = false, -- If true, moves focus back to terminal after diff opens
27-
on_unsaved_changes = "error", -- "error", "discard" - How to handle unsaved changes when creating diffs
27+
on_unsaved_changes = "error", -- "error", "discard" (discard uses :edit! to reload the file and will lose unsaved changes)
2828
},
2929
models = {
3030
{ name = "Claude Opus 4.1 (Latest)", value = "opus" },

0 commit comments

Comments
 (0)