File tree Expand file tree Collapse file tree 2 files changed +3
-1
lines changed Expand file tree Collapse file tree 2 files changed +3
-1
lines changed Original file line number Diff line number Diff line change 2
2
const dargs = require ( 'dargs' ) ;
3
3
const execa = require ( 'execa' ) ;
4
4
const PluginError = require ( 'plugin-error' ) ;
5
+ const supportsColor = require ( 'supports-color' ) ;
5
6
const through = require ( 'through2' ) ;
6
7
// TODO: Use execa localDir option when available
7
8
const npmRunPath = require ( 'npm-run-path' ) ;
@@ -16,7 +17,7 @@ const MULTIPLE_OPTS = new Set([
16
17
17
18
module . exports = opts => {
18
19
opts = Object . assign ( {
19
- colors : true ,
20
+ colors : Boolean ( supportsColor . stdout ) ,
20
21
suppress : false
21
22
} , opts ) ;
22
23
Original file line number Diff line number Diff line change 39
39
"mocha" : " ^5.2.0" ,
40
40
"npm-run-path" : " ^2.0.2" ,
41
41
"plugin-error" : " ^0.1.2" ,
42
+ "supports-color" : " ^5.4.0" ,
42
43
"through2" : " ^2.0.3"
43
44
},
44
45
"devDependencies" : {
You can’t perform that action at this time.
0 commit comments