From 14efcc748597f8b00d362df26adf5c4b4b7777f7 Mon Sep 17 00:00:00 2001 From: "Shawn O. Pearce" Date: Sun, 21 Jan 2007 13:34:00 -0500 Subject: [PATCH] git-gui: Correct unmerged file detection at commit time. Its impossible to commit an index which has unmerged stages. Unfortunately a bug in git-gui allowed the user to try to do exactly that, as we broke out of our file scanning loop as soon as we found a valid AMD index state. That's wrong, as the files are coming back from our array in pseudo-random order; an unmerged file may get returned only after all merged files. I also noticed the grammer around here in our dialog boxes still used the term 'include', so this has been updated to reflect current usage. Signed-off-by: Shawn O. Pearce --- git-gui.sh | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/git-gui.sh b/git-gui.sh index f618a60d7..32c33672d 100755 --- a/git-gui.sh +++ b/git-gui.sh @@ -896,12 +896,12 @@ The rescan will be automatically started now. _? {continue} A? - D? - - M? {set files_ready 1; break} + M? {set files_ready 1} U? { error_popup "Unmerged files cannot be committed. File [short_path $path] has merge conflicts. -You must resolve them and include the file before committing. +You must resolve them and add the file before committing. " unlock_index return @@ -915,9 +915,9 @@ File [short_path $path] cannot be committed by this program. } } if {!$files_ready} { - error_popup {No included files to commit. + error_popup {No changes to commit. -You must include at least 1 file before you can commit. +You must add at least 1 file before you can commit. } unlock_index return -- 2.26.2