mirror of
https://github.com/jesseduffield/lazygit.git
synced 2026-09-10 15:46:26 -04:00
fix windows bash conditional error
This commit is contained in:
parent
fc2e3a5316
commit
7e5d7bfe38
|
|
@ -178,10 +178,11 @@ func getGitBranches() []Branch {
|
|||
if branchCheck == "" {
|
||||
return append(branches, branchFromLine("master", 0))
|
||||
}
|
||||
rawString, _ := runDirectCommand(getBranchesCommand)
|
||||
branchLines := splitLines(rawString)
|
||||
for i, line := range branchLines {
|
||||
branches = append(branches, branchFromLine(line, i))
|
||||
if rawString, err := runDirectCommand(getBranchesCommand); err == nil {
|
||||
branchLines := splitLines(rawString)
|
||||
for i, line := range branchLines {
|
||||
branches = append(branches, branchFromLine(line, i))
|
||||
}
|
||||
}
|
||||
branches = getAndMergeFetchedBranches(branches)
|
||||
return branches
|
||||
|
|
|
|||
Loading…
Reference in a new issue