1
0
mirror of https://github.com/jesseduffield/lazygit.git synced 2025-06-15 00:15:32 +02:00

load reflog commits in two stages to speed up startup time

This commit is contained in:
Jesse Duffield
2020-03-28 11:22:11 +11:00
parent 19604214d7
commit 3f7ec3f3b8
5 changed files with 61 additions and 17 deletions

View File

@ -178,6 +178,12 @@ type searchingState struct {
searchString string
}
// startup stages so we don't need to load everything at once
const (
INITIAL = iota
COMPLETE
)
type guiState struct {
Files []*commands.File
Branches []*commands.Branch
@ -208,6 +214,7 @@ type guiState struct {
PrevMainWidth int
PrevMainHeight int
OldInformation string
StartupStage int // one of INITIAL and COMPLETE. Allows us to not load everything at once
}
// for now the split view will always be on