Skip to content

Commit 2112be7

Browse files
hvoigtspearce
authored andcommitted
git-gui: remove warning when deleting correctly merged remote branch
If the user wants to delete a remote branch and selects the correct "merged into" we should not warn that "Recovering deleted branches is difficult". For local branches we do the same already. Signed-off-by: Heiko Voigt <[email protected]> Signed-off-by: Shawn O. Pearce <[email protected]>
1 parent 2ee94d1 commit 2112be7

File tree

1 file changed

+9
-7
lines changed

1 file changed

+9
-7
lines changed

lib/remote_branch_delete.tcl

Lines changed: 9 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -208,13 +208,15 @@ method _delete {} {
208208
return
209209
}
210210

211-
if {[tk_messageBox \
212-
-icon warning \
213-
-type yesno \
214-
-title [wm title $w] \
215-
-parent $w \
216-
-message [mc "Recovering deleted branches is difficult.\n\nDelete the selected branches?"]] ne yes} {
217-
return
211+
if {$checktype ne {head}} {
212+
if {[tk_messageBox \
213+
-icon warning \
214+
-type yesno \
215+
-title [wm title $w] \
216+
-parent $w \
217+
-message [mc "Recovering deleted branches is difficult.\n\nDelete the selected branches?"]] ne yes} {
218+
return
219+
}
218220
}
219221

220222
destroy $w

0 commit comments

Comments
 (0)