Code

git-gui: Simplify error case for unsupported merge types
authorShawn O. Pearce <spearce@spearce.org>
Fri, 20 Jul 2007 07:37:43 +0000 (03:37 -0400)
committerShawn O. Pearce <spearce@spearce.org>
Sat, 21 Jul 2007 09:00:37 +0000 (05:00 -0400)
If we are given a merge type we don't understand in checkout_op there
is probably a bug in git-gui somewhere that allowed this unknown merge
strategy to come into this part of the code path.  We currently only
recognize three merge types ('none', 'ff' and 'reset') but are going
to be supporting more in the future.  Rather than keep editing this
message I'm going with a very generic "Uh, we don't do that!" type of
error.

Signed-off-by: Shawn O. Pearce <spearce@spearce.org>
lib/checkout_op.tcl

index 6d87830dd610c0c7cb8250671a79f8abae4501c1..554c107032458f3b9585b58d7920924acf0ecb69 100644 (file)
@@ -208,7 +208,7 @@ method _update_ref {} {
                                }
                        }
                        default {
-                               _error $this "Only 'ff' and 'reset' merge is currently supported."
+                               _error $this "Merge strategy '$merge_type' not supported."
                                return 0
                        }
                        }