1
0
mirror of https://github.com/jesseduffield/lazygit.git synced 2025-09-16 09:16:26 +02:00

fetching branches without checking out

This commit is contained in:
Jesse Duffield
2018-12-07 18:52:31 +11:00
parent ca3afa2a39
commit ff856b7630
18 changed files with 224 additions and 132 deletions

View File

@@ -64,7 +64,7 @@ func (gui *Gui) refreshFiles(g *gocui.Gui) error {
fmt.Fprint(filesView, list)
if filesView == g.CurrentView() {
gui.handleFileSelect(g, filesView)
return gui.handleFileSelect(g, filesView)
}
return nil
})
@@ -411,7 +411,7 @@ func (gui *Gui) pushWithForceFlag(currentView *gocui.View, force bool) error {
func (gui *Gui) pushFiles(g *gocui.Gui, v *gocui.View) error {
// if we have pullables we'll ask if the user wants to force push
_, pullables := gui.GitCommand.UpstreamDifferenceCount()
_, pullables := gui.GitCommand.GetCurrentBranchUpstreamDifferenceCount()
if pullables == "?" || pullables == "0" {
return gui.pushWithForceFlag(v, false)
}