diff options
author | Jesse Duffield <jessedduffield@gmail.com> | 2019-02-19 09:18:30 +1100 |
---|---|---|
committer | Jesse Duffield <jessedduffield@gmail.com> | 2019-02-19 09:18:30 +1100 |
commit | dcc7855fd0f04d68fa809d586ac7f45a534f7b25 (patch) | |
tree | d2da3fbae5460f220dd5ff9b204d28704fade1ec /pkg/gui/commits_panel.go | |
parent | a8e22ed82f39f514a4166675cb9dde0d3cb49f5c (diff) |
pull commit list builder functions into their own builder struct
Diffstat (limited to 'pkg/gui/commits_panel.go')
-rw-r--r-- | pkg/gui/commits_panel.go | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/pkg/gui/commits_panel.go b/pkg/gui/commits_panel.go index 374f7ccf0..f1d443731 100644 --- a/pkg/gui/commits_panel.go +++ b/pkg/gui/commits_panel.go @@ -7,6 +7,7 @@ import ( "github.com/jesseduffield/gocui" "github.com/jesseduffield/lazygit/pkg/commands" + "github.com/jesseduffield/lazygit/pkg/git" "github.com/jesseduffield/lazygit/pkg/utils" ) @@ -39,7 +40,11 @@ func (gui *Gui) handleCommitSelect(g *gocui.Gui, v *gocui.View) error { func (gui *Gui) refreshCommits(g *gocui.Gui) error { g.Update(func(*gocui.Gui) error { - commits, err := gui.GitCommand.GetCommits() + builder, err := git.NewCommitListBuilder(gui.Log, gui.GitCommand, gui.OSCommand) + if err != nil { + return err + } + commits, err := builder.GetCommits() if err != nil { return err } |