Skip to content

Commit

Permalink
Default to --no-colour for json, csv & file output.
Browse files Browse the repository at this point in the history
Color codes can be explicitly enabled with --color.
  • Loading branch information
timoxley committed Dec 4, 2014
1 parent 7e80d50 commit 11e204c
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions bin/license-checker
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,8 @@ var mkdirp = require('mkdirp');
var path = require('path');
var fs = require('fs');

if (!args.color && (args.json || args.csv || args.out)) args.color = false

checker.init(args, function(json) {
var formattedOutput = '';
if (args.json) formattedOutput = JSON.stringify(json, null, 2);
Expand Down

0 comments on commit 11e204c

Please sign in to comment.