stream-grep

0.1.0 • Public • Published

stream-grep

Streaming search for an array of regexs in a given stream, emits event when found.

build status

Installation

  npm install stream-grep

Usage

 
var streamGrep = require('..')
  , fs = require('fs')
 
streamGrep(fs.createReadStream(__filename), [/create/])
  .on('found', function (term, line) {
    console.log('Found', term, 'line', line)
  })
  .on('end', function(found) {
    console.log('Terms found', found)
  })
 

Credits

Paul Serby follow me on twitter @serby

Licence

Licensed under the New BSD License

Readme

Keywords

none

Package Sidebar

Install

npm i stream-grep

Weekly Downloads

8

Version

0.1.0

License

none

Last publish

Collaborators

  • serby