1
0
mirror of https://github.com/jesseduffield/lazygit.git synced 2025-02-03 13:21:56 +02:00

Print entire panic message

For some reason, the panic message was being truncated. So here we're printing it first, and then calling panic
This commit is contained in:
Jesse Duffield 2023-07-02 14:21:26 +10:00
parent 4df353d006
commit c9a917b830

View File

@ -2,6 +2,7 @@ package gui
import (
"fmt"
"os"
"strings"
"time"
@ -70,7 +71,8 @@ func (self *GuiDriver) Fail(message string) {
self.gui.g.Close()
// need to give the gui time to close
time.Sleep(time.Millisecond * 100)
panic(fullMessage)
fmt.Fprintln(os.Stderr, fullMessage)
panic("Test failed")
}
// logs to the normal place that you log to i.e. viewable with `lazygit --logs`