Skip to content

isaacs/fgrep

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

13 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

fgrep

Search for a given string in specified files.

As requested by David Herman

USAGE

var fgrep = require('fgrep')

// options:
// - limit: defaults to 10, how many files to read at once
// - nocase: defaults false, do a case-insensitive search
fgrep(string, filenames, options)
  .on('data', function (match) {
    // match is { filename, linenumber, line }
  })
  .on('end', function () {
    // done matching
  })

// or if you prefer being classy, but it's the same thing
var FGrep = require('fgrep')
var fg = new FGrep(string, filenames, limit)

About

Search for a given string in specified files.

Resources

License

Stars

Watchers

Forks

Sponsor this project

 

Packages

No packages published