From 7a89fd9f7248fcdd47242a1c07dc5f15e861532b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ionic=C4=83=20Biz=C4=83u?= Date: Sun, 11 Oct 2015 12:30:38 +0300 Subject: [PATCH] Format raw data --- bin/git-stats | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/bin/git-stats b/bin/git-stats index 2ede216..97e77f8 100755 --- a/bin/git-stats +++ b/bin/git-stats @@ -63,6 +63,7 @@ var recordOpt = new Clp.Option(["record"], "Records a new commit. Don't use this , dataPathOpt , firstDayOpt , recordOpt + , rawOpt ]) , options = null ; @@ -148,6 +149,9 @@ if (!authorsOpt.is_provided || globalActivityOpt.is_provided) { function display (err, data) { if (err) { return Logger.log(err, "error"); } + if (typeof data !== "string") { + data = JSON.stringify(data); + } process.stdout.write(data + "\n"); }