Skip to content

Commit

Permalink
refactor: remove supports-color
Browse files Browse the repository at this point in the history
  • Loading branch information
iiroj committed Jun 1, 2022
1 parent 659c85c commit 50f95b3
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 21 deletions.
6 changes: 3 additions & 3 deletions bin/lint-staged.js
Expand Up @@ -4,16 +4,16 @@ import fs from 'node:fs'
import path from 'node:path'
import { fileURLToPath } from 'node:url'

import { isColorSupported } from 'colorette'
import { Option, program } from 'commander'
import debug from 'debug'
import supportsColor from 'supports-color'

import lintStaged from '../lib/index.js'
import { CONFIG_STDIN_ERROR } from '../lib/messages.js'

// Force colors for packages that depend on https://www.npmjs.com/package/supports-color
if (supportsColor.stdout) {
process.env.FORCE_COLOR = supportsColor.stdout.level.toString()
if (isColorSupported) {
process.env.FORCE_COLOR = '1'
}

// Do not terminate main Listr process on SIGINT
Expand Down
17 changes: 0 additions & 17 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 0 additions & 1 deletion package.json
Expand Up @@ -44,7 +44,6 @@
"object-inspect": "^1.12.2",
"pidtree": "^0.5.0",
"string-argv": "^0.3.1",
"supports-color": "^9.2.2",
"yaml": "^2.1.1"
},
"devDependencies": {
Expand Down

0 comments on commit 50f95b3

Please sign in to comment.