Skip to content

Commit d93d781

Browse files
committed
Check if file is still conflicted before opening diffview. Item may have
a conflict mode (UU, etc), but the markers were resolved, and it should therefor no longer be considered for resolution.
1 parent 4ba620a commit d93d781

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

lua/neogit/buffers/status/actions.lua

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1162,7 +1162,7 @@ M.n_stage = function(self)
11621162
end
11631163

11641164
if selection.item and selection.item.mode == "UU" then
1165-
if config.check_integration("diffview") then
1165+
if config.check_integration("diffview") and git.merge.is_conflicted(selection.item.escaped_path) then
11661166
require("neogit.integrations.diffview").open("conflict", selection.item.name, {
11671167
on_close = {
11681168
handle = self.buffer.handle,

0 commit comments

Comments
 (0)