aboutsummaryrefslogtreecommitdiff
path: root/helper.go
diff options
context:
space:
mode:
authorDimitri Sokolyuk <demon@dim13.org>2015-11-27 14:42:12 +0100
committerDimitri Sokolyuk <demon@dim13.org>2015-11-27 14:42:12 +0100
commit0456617941c2508cf128a04ebfb58c8d2169586f (patch)
treef1cb94f64af003e05ddf4972f93f23ed7ccc35e8 /helper.go
parent6c0b2240d3d53621e0b145b1bd1b79a3826e3485 (diff)
WIP
Diffstat (limited to 'helper.go')
-rw-r--r--helper.go15
1 files changed, 15 insertions, 0 deletions
diff --git a/helper.go b/helper.go
new file mode 100644
index 0000000..4315ac2
--- /dev/null
+++ b/helper.go
@@ -0,0 +1,15 @@
+package acme
+
+import (
+ "encoding/json"
+ "fmt"
+)
+
+func Dump(v interface{}) error {
+ body, err := json.MarshalIndent(v, "", "\t")
+ if err != nil {
+ return err
+ }
+ fmt.Println(string(body))
+ return nil
+}