Comparing version 0.2.1 to 0.3.0
@@ -30,2 +30,3 @@ // Load modules | ||
internals.purdy = function (object, options) { | ||
@@ -36,4 +37,8 @@ | ||
internals.stringify = function (object, options) { | ||
if (!process.stdout.isTTY) { | ||
internals.defaults.plain = true; | ||
} | ||
internals.settings = Hoek.applyToDefaults(internals.defaults, options || {}); | ||
@@ -43,2 +48,3 @@ return internals.travel(object); | ||
internals.purdy.stringify = internals.stringify; | ||
@@ -65,2 +71,3 @@ | ||
internals.colorize = function (string, type) { | ||
@@ -92,2 +99,3 @@ | ||
internals.Object = function(object) { | ||
@@ -152,2 +160,3 @@ | ||
internals.String = function(str) { | ||
@@ -175,2 +184,3 @@ | ||
internals.indent = function () { | ||
@@ -177,0 +187,0 @@ |
{ | ||
"name": "purdy", | ||
"version": "0.2.1", | ||
"version": "0.3.0", | ||
"description": "print objects real purdy in color", | ||
@@ -5,0 +5,0 @@ "main": "index.js", |
@@ -20,3 +20,3 @@ # Purdy | ||
* `options` - optional object with the following keys. | ||
* `plain` - when `true`, prints result without colors. Defaults to `false`. | ||
* `plain` - when `true`, prints result without colors. Defaults to `false` with tty, `true` when not. | ||
@@ -23,0 +23,0 @@ |
12760
250