X-Git-Url: https://git.octo.it/?a=blobdiff_plain;f=gitk;h=5362b76bee5ad0ee13964634ac12e7d73b85cdbb;hb=2effe71b7c3a78cd20070752e04fb04830e4dd36;hp=f88c06e565ce34cd3985ea22d35e33735ed4f0fa;hpb=a906ce6aa78ac8febf466b46c6fae029137cd506;p=git.git diff --git a/gitk b/gitk index f88c06e5..5362b76b 100755 --- a/gitk +++ b/gitk @@ -16,22 +16,6 @@ proc gitdir {} { } } -proc parse_args {rargs} { - global parsed_args - - if {[catch { - set parse_args [concat --default HEAD $rargs] - set parsed_args [split [eval exec git-rev-parse $parse_args] "\n"] - }]} { - # if git-rev-parse failed for some reason... - if {$rargs == {}} { - set rargs HEAD - } - set parsed_args $rargs - } - return $parsed_args -} - proc start_rev_list {rlargs} { global startmsecs nextupdate ncmupdate global commfd leftover tclencoding datemode @@ -46,7 +30,7 @@ proc start_rev_list {rlargs} { } if {[catch { set commfd [open [concat | git-rev-list --header $order \ - --parents --boundary $rlargs] r] + --parents --boundary --default HEAD $rlargs] r] } err]} { puts stderr "Error executing git-rev-list: $err" exit 1 @@ -65,7 +49,7 @@ proc getcommits {rargs} { global phase canv mainfont set phase getcommits - start_rev_list [parse_args $rargs] + start_rev_list $rargs $canv delete all $canv create text 3 3 -anchor nw -text "Reading commits..." \ -font $mainfont -tags textitems @@ -1116,11 +1100,12 @@ proc layoutrows {row endrow last} { proc addextraid {id row} { global displayorder commitrow commitinfo - global commitidx + global commitidx commitlisted global parentlist childlist children incr commitidx lappend displayorder $id + lappend commitlisted 0 lappend parentlist {} set commitrow($id) $row readcommit $id @@ -1500,7 +1485,7 @@ proc drawcmittext {id row col rmx} { proc drawcmitrow {row} { global displayorder rowidlist global idrowranges idrangedrawn iddrawn - global commitinfo commitlisted parentlist numcommits + global commitinfo parentlist numcommits if {$row >= $numcommits} return foreach id [lindex $rowidlist $row] {