{"name":"is-interactive","version":"1.0.0","description":"Check if stdout or stderr is interactive","license":"MIT","repository":{"type":"git","url":"git+https://github.com/sindresorhus/is-interactive.git"},"author":{"name":"Sindre Sorhus","email":"sindresorhus@gmail.com","url":"sindresorhus.com"},"engines":{"node":">=8"},"scripts":{"test":"xo && ava && tsd"},"keywords":["interactive","stdout","stderr","detect","is","terminal","shell","tty"],"devDependencies":{"@types/node":"^12.0.12","ava":"^2.1.0","tsd":"^0.7.3","xo":"^0.24.0"},"gitHead":"b4b4bda46dc6a5c5b8e347b2561fd3625a927f8d","bugs":{"url":"https://github.com/sindresorhus/is-interactive/issues"},"homepage":"https://github.com/sindresorhus/is-interactive#readme","_id":"is-interactive@1.0.0","_nodeVersion":"10.16.0","_npmVersion":"6.9.0","_npmUser":{"name":"sindresorhus","email":"sindresorhus@gmail.com"},"dist":{"integrity":"sha512-2HvIEKRoqS62guEC+qBjpvRubdX910WCMuJTZ+I9yvqKU2/12eSL549HMwtabb4oupdj2sMP50k+XJfB/8JE6w==","shasum":"cea6e6ae5c870a7b0a0004070b7b587e0252912e","tarball":"http://registry-npm.ywwl.com/is-interactive/download/is-interactive-1.0.0.tgz","fileCount":5,"unpackedSize":4619,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.4\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJdNIVMCRA9TVsSAnZWagAAyMwP/iI9w+rD5KltF3LQOeiW\nIrj64r1JZYvFnDwtMhmmDq5FKZubUXvI0c/WqDAvlzv0qbt9rt583NZeOadb\nuU3M/3S8epBJ2/5VDw2Q9BSLu3zgztPSC/8F9rX/qRW3X2MH0PNDYPmXN7uf\ns1IMqrNT0BG0ITRoYOTYNUHZDG7E1gy7oofppIxk+XFGM9RXVkv6PQs7tgwU\nx7nRjn4j+ofXul4QbvLbrX273IAcXX39TCr/CxVxHB7XtBQkpa1bpu/bsYfH\nzA/gRLKfRessstWe1r8oMh5j9bSvDi7uQZLGXEvP+fq0+XIvHwyC9vDnvor1\n8mSADCCeM6JTkdDln6fFdfLrYEAosXWm6OH6Ilo8I2SUQ9IyGtqp2e4iPbzA\nV2Nqp0WhoKb/dbpL5glp5GelyGmdSUeAbAiNDk2a1VsovRzbDVVGOzHoclWw\nkLQTXqGq1sDCUu8JZ+0KrNHkvSnwpC9RaSPvQLXPoe5HOliffuynTcGX/rBe\ndklMvhsNq08Pp9c+jWMAjsPaCQdyE8+3WZbb6Uu4HuaSr/EjgFye5P29uy8s\nz5usDX9VHkoCHFeLF/lZVQIBUPgUqiff+GTexXYFvqKVYladdE3gLKbM++w6\nM/ixRVErfOEf8WhSm6PZ+4C7LRawOd0hanW0c0IpmD91qIAjmYtYacbG9wF/\nFKki\r\n=bg8c\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEQCIB5AQWi7NPX8twOB2tkrQdtz4T/+ot3lGsWORzlNx+ifAiA8EgpXWIJPpsSU08WhMgSKGN03VDw/BXrO9ZxU1xYf8A=="}],"size":2412,"noattachment":false,"key":"/is-interactive/-/is-interactive-1.0.0.tgz"},"maintainers":[{"name":"sindresorhus","email":"sindresorhus@gmail.com"}],"directories":{},"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/is-interactive_1.0.0_1563723083759_0.9837731888386234"},"_hasShrinkwrap":false,"readme":"# is-interactive\n\n> Check if stdout or stderr is [interactive](https://unix.stackexchange.com/a/43389/7678)\n\nIt checks that the stream is [TTY](https://jameshfisher.com/2017/12/09/what-is-a-tty/), not a dumb terminal, and not running in a CI.\n\nThis can be useful to decide whether to present interactive UI or animations in the terminal.\n\n## Install\n\n```\n$ npm install is-interactive\n```\n\n## Usage\n\n```js\nimport isInteractive from 'is-interactive';\n\nisInteractive();\n//=> true\n```\n\n## API\n\n### isInteractive(options?)\n\n#### options\n\nType: `object`\n\n##### stream\n\nType: [`stream.Writable`](https://nodejs.org/api/stream.html#stream_class_stream_writable)\\\nDefault: [`process.stdout`](https://nodejs.org/api/process.html#process_process_stdout)\n\nThe stream to check.\n\n## FAQ\n\n#### Why are you not using [`ci-info`](https://github.com/watson/ci-info) for the CI check?\n\nIt's silly to have to detect individual CIs. They should identify themselves with the `CI` environment variable, and most do just that. A manually maintained list of detections will easily get out of date. And if a package using `ci-info` doesn't update to the latest version all the time, they will not support certain CIs. It also creates unpredictability as you might assume a CI is not supported and then suddenly it gets supported and you didn't account for that. In addition, some of the manual detections are loose and might cause false-positives which could create hard-to-debug bugs.\n\n#### Why does this even exist? It's just a few lines.\n\nIt's not about the number of lines, but rather discoverability and documentation. A lot of people wouldn't even know they need this. Feel free to copy-paste the code if you don't want the dependency. You might also want to read [this blog post](https://blog.sindresorhus.com/small-focused-modules-9238d977a92a).\n\n## Related\n\n- [is-unicode-supported](https://github.com/sindresorhus/is-unicode-supported) - Detect whether the terminal supports Unicode\n- [supports-color](https://github.com/chalk/supports-color) - Detect whether a terminal supports color\n","publish_time":1563723083890,"_cnpm_publish_time":1563723083890,"dist-tags":{"latest":"2.0.0"}}