1
0
mirror of https://github.com/jesseduffield/lazygit.git synced 2025-12-01 22:52:01 +02:00

logging durations and more stuff

This commit is contained in:
Jesse Duffield
2018-06-02 08:35:49 +10:00
parent a555a75565
commit 103a6fd219
10 changed files with 73 additions and 93 deletions

View File

@@ -9,6 +9,7 @@ package main
import (
"fmt"
"strings"
"time"
"github.com/jroimartin/gocui"
)
@@ -97,6 +98,7 @@ func correctCursor(v *gocui.View) error {
func renderString(g *gocui.Gui, viewName, s string) error {
g.Update(func(*gocui.Gui) error {
timeStart := time.Now()
v, err := g.View(viewName)
if err != nil {
panic(err)
@@ -104,6 +106,7 @@ func renderString(g *gocui.Gui, viewName, s string) error {
v.Clear()
fmt.Fprint(v, s)
v.Wrap = true
devLog("render time: ", time.Now().Sub(timeStart))
return nil
})
return nil