* https://github.com/prati0100/git-gui: git-gui: allow opening currently selected file in default app git-gui: allow closing console window with Escape git gui: fix branch name encoding error git-gui: revert untracked files by deleting them git-gui: update status bar to track operations git-gui: consolidate naming conventions
This commit is contained in:
@ -341,9 +341,9 @@ method _readtree {} {
|
||||
global HEAD
|
||||
|
||||
set readtree_d {}
|
||||
$::main_status start \
|
||||
set status_bar_operation [$::main_status start \
|
||||
[mc "Updating working directory to '%s'..." [_name $this]] \
|
||||
[mc "files checked out"]
|
||||
[mc "files checked out"]]
|
||||
|
||||
set fd [git_read --stderr read-tree \
|
||||
-m \
|
||||
@ -354,26 +354,27 @@ method _readtree {} {
|
||||
$new_hash \
|
||||
]
|
||||
fconfigure $fd -blocking 0 -translation binary
|
||||
fileevent $fd readable [cb _readtree_wait $fd]
|
||||
fileevent $fd readable [cb _readtree_wait $fd $status_bar_operation]
|
||||
}
|
||||
|
||||
method _readtree_wait {fd} {
|
||||
method _readtree_wait {fd status_bar_operation} {
|
||||
global current_branch
|
||||
|
||||
set buf [read $fd]
|
||||
$::main_status update_meter $buf
|
||||
$status_bar_operation update_meter $buf
|
||||
append readtree_d $buf
|
||||
|
||||
fconfigure $fd -blocking 1
|
||||
if {![eof $fd]} {
|
||||
fconfigure $fd -blocking 0
|
||||
$status_bar_operation stop
|
||||
return
|
||||
}
|
||||
|
||||
if {[catch {close $fd}]} {
|
||||
set err $readtree_d
|
||||
regsub {^fatal: } $err {} err
|
||||
$::main_status stop [mc "Aborted checkout of '%s' (file level merging is required)." [_name $this]]
|
||||
$status_bar_operation stop [mc "Aborted checkout of '%s' (file level merging is required)." [_name $this]]
|
||||
warn_popup [strcat [mc "File level merge required."] "
|
||||
|
||||
$err
|
||||
@ -384,7 +385,7 @@ $err
|
||||
return
|
||||
}
|
||||
|
||||
$::main_status stop
|
||||
$status_bar_operation stop
|
||||
_after_readtree $this
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user