Skip to content
Closed
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
Update tty.js
  • Loading branch information
Richienb authored Oct 9, 2021
commit eed74692827c69fb8242a45569afc2aa7b7cba6b
12 changes: 9 additions & 3 deletions lib/internal/tty.js
Original file line number Diff line number Diff line change
Expand Up @@ -159,9 +159,15 @@ function getColorDepth(env = process.env) {
}

if (env.CI) {
if ('TRAVIS' in env || 'CIRCLECI' in env || 'APPVEYOR' in env ||
'GITLAB_CI' in env || 'GITHUB_ACTIONS' in env || 'BUILDKITE' in env ||
'DRONE' in env || env.CI_NAME === 'codeship') {
if ([
'TRAVIS',
'CIRCLECI',
'APPVEYOR',
'GITLAB_CI',
'GITHUB_ACTIONS',
'BUILDKITE',
'DRONE'
].some(sign => sign in env) || env.CI_NAME === 'codeship') {
return COLORS_256;
}
return COLORS_2;
Expand Down