summaryrefslogtreecommitdiffstats
path: root/main.go
diff options
context:
space:
mode:
authorJesse Duffield <jessedduffield@gmail.com>2018-08-11 15:04:02 +1000
committerJesse Duffield <jessedduffield@gmail.com>2018-08-11 15:04:02 +1000
commit73e740d1ba45e6c01988953234f8e217b811d1dc (patch)
tree32cf62bbbad398e883373609d3cb5b1c7816ef9e /main.go
parentf1eaeec9eeddc4c676524d6c9dd6f8737a70e6ac (diff)
clean up fixup code
reduce log clutter add log dumping with spew
Diffstat (limited to 'main.go')
-rw-r--r--main.go10
1 files changed, 10 insertions, 0 deletions
diff --git a/main.go b/main.go
index c918c7348..426f47eee 100644
--- a/main.go
+++ b/main.go
@@ -11,6 +11,8 @@ import (
"os/user"
"path/filepath"
+ "github.com/davecgh/go-spew/spew"
+
"github.com/jesseduffield/gocui"
git "gopkg.in/src-d/go-git.v4"
)
@@ -47,6 +49,14 @@ func devLog(objects ...interface{}) {
localLog("development.log", objects...)
}
+func objectLog(object interface{}) {
+ if !*debuggingFlag {
+ return
+ }
+ str := spew.Sdump(object)
+ localLog("development.log", str)
+}
+
func commandLog(objects ...interface{}) {
localLog("commands.log", objects...)
}