{"name":"get-stdin","version":"9.0.0","description":"Get stdin as a string or buffer","license":"MIT","repository":{"type":"git","url":"git+https://github.com/sindresorhus/get-stdin.git"},"funding":"https://github.com/sponsors/sindresorhus","author":{"name":"Sindre Sorhus","email":"sindresorhus@gmail.com","url":"https://sindresorhus.com"},"type":"module","exports":"./index.js","engines":{"node":">=12"},"scripts":{"test":"xo && ava test.js test-buffer.js && echo unicorns | node test-real.js && tsd"},"keywords":["std","stdin","stdio","concat","buffer","stream","process","read"],"devDependencies":{"@types/node":"^14.14.41","ava":"^3.15.0","delay":"^5.0.0","tsd":"^0.14.0","xo":"^0.38.2"},"gitHead":"147d91ccdb23748b4655192781928df9f4fb4aee","bugs":{"url":"https://github.com/sindresorhus/get-stdin/issues"},"homepage":"https://github.com/sindresorhus/get-stdin#readme","_id":"get-stdin@9.0.0","_nodeVersion":"14.16.1","_npmVersion":"6.14.10","_npmUser":{"name":"sindresorhus","email":"sindresorhus@gmail.com"},"dist":{"integrity":"sha512-dVKBjfWisLAicarI2Sf+JuBE/DghV4UzNAVe9yhEJuzeREd3JhOTE9cUaJTeSa77fsbQUK3pcOpJfM59+VKZaA==","shasum":"3983ff82e03d56f1b2ea0d3e60325f39d703a575","tarball":"http://registry-npm.ywwl.com/get-stdin/download/get-stdin-9.0.0.tgz","fileCount":5,"unpackedSize":4535,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.13\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJgeTqXCRA9TVsSAnZWagAACPoQAJk5NHpGchcKNqyfIFgR\ndrVCROKsyyIDUNQZqWt/evQCj7RPfEHchkvp2da5dDoGeW63Y4IKJ1bVEmZp\nX+5cYUInH9yAwseUfO8eHa/CB1/Ilt6IZJYGvOswB4Ahz6LBaZQjfSJAWvBy\n2faNJtP1VSd32XLXXkvuwvpuyDJEg0xsC6mYKMWTp8B3gbClxtZ39Xf4PTf/\ndxjlv2YAe7yn2aD4SKopFFbSMuQ4LLEedBvKMAZs9uZTnUnSTtIM5y70G4ql\nEP5fc819UKTAxmCuvGb8jqGLtH2WGZDnRqq/xPknTRtvHjlp/jcO/kAQMSzC\nvimvIgrxhJJ1DM95bxkihS/p5Oe+L77JUk117hHx7PdTfPgXukhz4Bt7bcje\nMyrmaKeac9CABNZPsFBChszHkuUVrCeH5R81xuxZB311So66fBZBd3WXGDPc\nTCp5Qp6rrNqRcJjZ25ZCcLeZI/k0/SLcTRYjVQOEV0VFjnrHnPtwTE64tM4i\nBELcoRTyQo8Bz8uuEAbJMzpPFgzQiIdNwjsW4/cLeJs+3DWf9JuhCr9FtrvO\ntBWy9Ua8rTSwM6fLYhSMVbpnmlQflQvYtudtAHfvKAsuIiOzJcD1Iwdf9XU5\nlfreGEJ2Dkiq48cdgdzzbfyZVHfhsDQMpeOtkF7gHJAfWTQBVCTva0oDhIAC\nUESP\r\n=qecS\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEQCID7WhSStzUd98LBOpMORLOrDNVei2VQ3dGGnhfwNSMKfAiBe4XVhisSL4S/mLm+MEkkDw0wlnjw0u8Bn6c+8Fmch7A=="}],"size":2180,"noattachment":false,"key":"/get-stdin/-/get-stdin-9.0.0.tgz"},"directories":{},"maintainers":[{"name":"sindresorhus","email":"sindresorhus@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/get-stdin_9.0.0_1618557590571_0.1768780156948493"},"_hasShrinkwrap":false,"readme":"# get-stdin\n\n> Get [stdin](https://nodejs.org/api/process.html#process_process_stdin) as a string or buffer\n\n## Install\n\n```\n$ npm install get-stdin\n```\n\n## Usage\n\n```js\n// example.js\nimport getStdin from 'get-stdin';\n\nconsole.log(await getStdin());\n//=> 'unicorns'\n```\n\n```\n$ echo unicorns | node example.js\nunicorns\n```\n\n## API\n\nBoth methods returns a promise that is resolved when the `end` event fires on the `stdin` stream, indicating that there is no more data to be read.\n\n### getStdin()\n\nGet `stdin` as a `string`.\n\nIn a TTY context, a promise that resolves to an empty `string` is returned.\n\n### getStdin.buffer()\n\nGet `stdin` as a `Buffer`.\n\nIn a TTY context, a promise that resolves to an empty `Buffer` is returned.\n\n## Related\n\n- [get-stream](https://github.com/sindresorhus/get-stream) - Get a stream as a string or buffer\n\n---\n\n<div align=\"center\">\n\t<b>\n\t\t<a href=\"https://tidelift.com/subscription/pkg/npm-get-stdin?utm_source=npm-get-stdin&utm_medium=referral&utm_campaign=readme\">Get professional support for this package with a Tidelift subscription</a>\n\t</b>\n\t<br>\n\t<sub>\n\t\tTidelift helps make open source sustainable for maintainers while giving companies<br>assurances about security, maintenance, and licensing for their dependencies.\n\t</sub>\n</div>\n","publish_time":1618557590680,"_cnpm_publish_time":1618557590680,"dist-tags":{"latest":"10.0.0"}}