git-gui: Label the uncommitted blame history entry
If the user runs the blame viewer on a working directory file instead of a specific commit-ish then we have no value for the commit SHA1 or the summary line; this causes the history menu to get an empty entry at the very bottom. We now look for this odd case and call the meny entry "Working Directory". Signed-off-by: Shawn O. Pearce <spearce@spearce.org>
Shawn O. Pearce committed
Jun 2, 2007 at 16:03 UTC
c5db65aef3b4268adbadc8019ecbd7d3fdc374e8
1 file changed
+2
lib/blame.tcl
+2
@@ -370,6 +370,8 @@ method _history_menu {} {
370
371
if {[regexp {^[0-9a-f]{40}$} $c]} {
372
set t [string range $c 0 8]...
373
+ } elseif {$c eq {}} {
374
+ set t {Working Directory}
375
} else {
376
set t $c
377
}