mirror of
https://github.com/S2-/gitlit
synced 2025-08-04 05:10:05 +02:00
initial commit
This commit is contained in:
44
app/node_modules/get-stdin/readme.md
generated
vendored
Normal file
44
app/node_modules/get-stdin/readme.md
generated
vendored
Normal file
@@ -0,0 +1,44 @@
|
||||
# get-stdin [](https://travis-ci.org/sindresorhus/get-stdin)
|
||||
|
||||
> Easier stdin
|
||||
|
||||
|
||||
## Install
|
||||
|
||||
```sh
|
||||
$ npm install --save get-stdin
|
||||
```
|
||||
|
||||
|
||||
## Usage
|
||||
|
||||
```js
|
||||
// example.js
|
||||
var stdin = require('get-stdin');
|
||||
|
||||
stdin(function (data) {
|
||||
console.log(data);
|
||||
//=> unicorns
|
||||
});
|
||||
```
|
||||
|
||||
```sh
|
||||
$ echo unicorns | node example.js
|
||||
unicorns
|
||||
```
|
||||
|
||||
|
||||
## API
|
||||
|
||||
### stdin(callback)
|
||||
|
||||
Get `stdin` as a string.
|
||||
|
||||
### stdin.buffer(callback)
|
||||
|
||||
Get `stdin` as a buffer.
|
||||
|
||||
|
||||
## License
|
||||
|
||||
MIT © [Sindre Sorhus](http://sindresorhus.com)
|
Reference in New Issue
Block a user