{"name":"redstd","version":"1.0.1","keywords":["commandline","pipe","stdin"],"author":{"url":"http://coderaiser.github.io/","name":"coderaiser","email":"mnemonic.enemy@gmail.com"},"license":"MIT","_id":"redstd@1.0.1","maintainers":[{"name":"coderaiser","email":"mnemonic.enemy@gmail.com"}],"homepage":"https://github.com/coderaiser/redstd","bugs":{"url":"https://github.com/coderaiser/redstd/issues"},"dist":{"shasum":"25bf9fd32681fd8785cb8ee8a2551c43fbfddc2e","tarball":"http://registry-npm.ywwl.com/redstd/download/redstd-1.0.1.tgz","fileCount":7,"integrity":"sha512-zQPwzGBwIOEJuzALtfp3c81ykmaV2pBeFwGMvZz0HLF/OtWoM9434qRbxazTYzVGthAv98knaqPWULEpCnXW7w==","signatures":[{"sig":"MEUCIBnCsBe/aN24JOV0Ibt7Vi5o6vWAVaBALQ9XSrUeXqN7AiEAonSwaBsklJ0fN6zVtV7KnIOnHRf7sicsWl0xTo7u+b4=","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"unpackedSize":8261,"size":3919,"noattachment":false,"key":"/redstd/-/redstd-1.0.1.tgz"},"main":"lib/redstd.js","type":"module","engines":{"node":">=22"},"gitHead":"118c947cd450f8999a1021085c3b019edc31cb7a","scripts":{"lint":"madrun lint","test":"madrun test","hello":"madrun hello","report":"madrun report","prepare":"madrun prepare","watcher":"madrun watcher","coverage":"madrun coverage","fix:lint":"madrun fix:lint","fresh:lint":"madrun fresh:lint","lint:fresh":"madrun lint:fresh","watch:lint":"madrun watch:lint","watch:tape":"madrun watch:tape","watch:test":"madrun watch:test"},"_npmUser":{"name":"coderaiser","email":"mnemonic.enemy@gmail.com"},"repository":{"url":"git+https://github.com/coderaiser/redstd.git","type":"git"},"_npmVersion":"11.4.2","description":"read stin","directories":{},"_nodeVersion":"25.9.0","dependencies":{},"publishConfig":{"access":"public"},"_hasShrinkwrap":false,"devDependencies":{"eslint":"^10.0.0","madrun":"^13.0.1","nodemon":"^3.0.1","redlint":"^6.0.0","superc8":"^12.2.4","supertape":"^12.0.0","eslint-plugin-putout":"^31.0.0"},"_npmOperationalInternal":{"tmp":"tmp/redstd_1.0.1_1776262617829_0.7761995777855673","host":"s3://npm-registry-packages-npm-production"},"readme":"# redstd [![License][LicenseIMGURL]][LicenseURL] [![NPM version][NPMIMGURL]][NPMURL] [![Build Status][BuildStatusIMGURL]][BuildStatusURL] [![Coverage Status][CoverageIMGURL]][CoverageURL]\n\n[NPMURL]: https://npmjs.org/package/redstd \"npm\"\n[NPMIMGURL]: https://img.shields.io/npm/v/redstd.svg?style=flat\n[BuildStatusURL]: https://github.com/coderaiser/redstd/actions?query=workflow%3A%22Node+CI%22 \"Build Status\"\n[BuildStatusIMGURL]: https://github.com/coderaiser/redstd/workflows/Node%20CI/badge.svg\n[LicenseURL]: https://tldrlegal.com/license/mit-license \"MIT License\"\n[LicenseIMGURL]: https://img.shields.io/badge/license-MIT-317BF9.svg?style=flat\n[CoverageURL]: https://coveralls.io/github/coderaiser/redstd?branch=master\n[CoverageIMGURL]: https://coveralls.io/repos/coderaiser/redstd/badge.svg?branch=master&service=github\n\nRead `stdin` to have ability to use pipes like: `cat README.md | less` or\n\n```sh\ncat README.md | node -e \"const {readStdin} = await import('redstd'); console.log(await readStdin())\"\n```\n\nWhen you pass nothing to stdin - everything just works, so you can read from stdout or from file\n\n## Install\n\n```\nnpm i redstd\n```\n\n# Usage\n\n```js\nimport {readFile} from 'node:fs/promises';\nimport {readStdin} from 'redstd';\n\nconst input = await readStdin();\n\nif (!input) {\n    console.log(await readFile('./README.md'));\n    process.exit();\n}\n\nconsole.log(input);\n```\n\n## License\n\nMIT\n","publish_time":1776262618002,"_cnpm_publish_time":1776262618002,"dist-tags":{"latest":"1.0.2"}}