Socket
Socket
Sign inDemoInstall

supports-color

Package Overview
Dependencies
0
Maintainers
2
Versions
50
Alerts
File Explorer

Advanced tools

Install Socket

Detect and block malicious and high-risk dependencies

Install

Comparing version 9.3.0 to 9.3.1

2

index.d.ts

@@ -1,2 +0,2 @@

import {WriteStream} from 'node:tty';
import type {WriteStream} from 'node:tty';

@@ -3,0 +3,0 @@ export interface Options {

@@ -6,3 +6,4 @@ import process from 'node:process';

// From: https://github.com/sindresorhus/has-flag/blob/main/index.js
function hasFlag(flag, argv = globalThis.Deno?.args ?? process.argv) {
/// function hasFlag(flag, argv = globalThis.Deno?.args ?? process.argv) {
function hasFlag(flag, argv = globalThis.Deno ? globalThis.Deno.args : process.argv) {
const prefix = flag.startsWith('-') ? '' : (flag.length === 1 ? '-' : '--');

@@ -142,6 +143,9 @@ const position = argv.indexOf(prefix + flag);

switch (env.TERM_PROGRAM) {
case 'iTerm.app':
case 'iTerm.app': {
return version >= 3 ? 3 : 2;
case 'Apple_Terminal':
}
case 'Apple_Terminal': {
return 2;
}
// No default

@@ -148,0 +152,0 @@ }

{
"name": "supports-color",
"version": "9.3.0",
"version": "9.3.1",
"description": "Detect whether a terminal supports color",

@@ -59,4 +59,4 @@ "license": "MIT",

"typescript": "^4.4.3",
"xo": "^0.44.0"
"xo": "^0.49.0"
}
}
SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc