diff options
Diffstat (limited to 'node_modules/glob-watcher')
-rw-r--r-- | node_modules/glob-watcher/.npmignore | 6 | ||||
-rw-r--r-- | node_modules/glob-watcher/.travis.yml | 6 | ||||
-rwxr-xr-x | node_modules/glob-watcher/LICENSE | 20 | ||||
-rw-r--r-- | node_modules/glob-watcher/README.md | 53 | ||||
-rw-r--r-- | node_modules/glob-watcher/index.js | 39 | ||||
-rw-r--r-- | node_modules/glob-watcher/package.json | 35 | ||||
-rw-r--r-- | node_modules/glob-watcher/test/fixtures/test.coffee | 1 | ||||
-rw-r--r-- | node_modules/glob-watcher/test/main.js | 87 |
8 files changed, 0 insertions, 247 deletions
diff --git a/node_modules/glob-watcher/.npmignore b/node_modules/glob-watcher/.npmignore deleted file mode 100644 index b5ef13a3c..000000000 --- a/node_modules/glob-watcher/.npmignore +++ /dev/null @@ -1,6 +0,0 @@ -.DS_Store -*.log -node_modules -build -*.node -components
\ No newline at end of file diff --git a/node_modules/glob-watcher/.travis.yml b/node_modules/glob-watcher/.travis.yml deleted file mode 100644 index 33ad9f8c8..000000000 --- a/node_modules/glob-watcher/.travis.yml +++ /dev/null @@ -1,6 +0,0 @@ -language: node_js -node_js: - - "0.9" - - "0.10" -after_script: - - npm run coveralls
\ No newline at end of file diff --git a/node_modules/glob-watcher/LICENSE b/node_modules/glob-watcher/LICENSE deleted file mode 100755 index 4f482f9ba..000000000 --- a/node_modules/glob-watcher/LICENSE +++ /dev/null @@ -1,20 +0,0 @@ -Copyright (c) 2013 Fractal <contact@wearefractal.com> - -Permission is hereby granted, free of charge, to any person obtaining -a copy of this software and associated documentation files (the -"Software"), to deal in the Software without restriction, including -without limitation the rights to use, copy, modify, merge, publish, -distribute, sublicense, and/or sell copies of the Software, and to -permit persons to whom the Software is furnished to do so, subject to -the following conditions: - -The above copyright notice and this permission notice shall be -included in all copies or substantial portions of the Software. - -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, -EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND -NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE -LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION -OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION -WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. diff --git a/node_modules/glob-watcher/README.md b/node_modules/glob-watcher/README.md deleted file mode 100644 index 129311ebc..000000000 --- a/node_modules/glob-watcher/README.md +++ /dev/null @@ -1,53 +0,0 @@ -# glob-watcher [![NPM version][npm-image]][npm-url] [![Build Status][travis-image]][travis-url] [![Coveralls Status][coveralls-image]][coveralls-url] [![Dependency Status][david-image]][david-url] - -## Information - -<table> -<tr> -<td>Package</td><td>glob-watcher</td> -</tr> -<tr> -<td>Description</td> -<td>Watch globs</td> -</tr> -<tr> -<td>Node Version</td> -<td>>= 0.9</td> -</tr> -</table> - -## Usage - -```javascript -var watch = require('glob-watcher'); - -// callback interface -watch(["./*.js", "!./something.js"], function(evt){ - // evt has what file changed and all that jazz -}); - -// EE interface -var watcher = watch(["./*.js", "!./something.js"]); -watcher.on('change', function(evt) { - // evt has what file changed and all that jazz -}); - -// add files after it has been created -watcher.add("./somefolder/somefile.js"); -``` - - -[npm-url]: https://npmjs.org/package/glob-watcher -[npm-image]: https://badge.fury.io/js/glob-watcher.png - -[travis-url]: https://travis-ci.org/wearefractal/glob-watcher -[travis-image]: https://travis-ci.org/wearefractal/glob-watcher.png?branch=master - -[coveralls-url]: https://coveralls.io/r/wearefractal/glob-watcher -[coveralls-image]: https://coveralls.io/repos/wearefractal/glob-watcher/badge.png - -[depstat-url]: https://david-dm.org/wearefractal/glob-watcher -[depstat-image]: https://david-dm.org/wearefractal/glob-watcher.png - -[david-url]: https://david-dm.org/wearefractal/glob-watcher -[david-image]: https://david-dm.org/wearefractal/glob-watcher.png?theme=shields.io diff --git a/node_modules/glob-watcher/index.js b/node_modules/glob-watcher/index.js deleted file mode 100644 index 907defd4e..000000000 --- a/node_modules/glob-watcher/index.js +++ /dev/null @@ -1,39 +0,0 @@ -var gaze = require('gaze'); -var EventEmitter = require('events').EventEmitter; - -module.exports = function(glob, opts, cb) { - var out = new EventEmitter(); - - if (typeof opts === 'function') { - cb = opts; - opts = {}; - } - - var watcher = gaze(glob, opts, function(err, rwatcher){ - if (err) out.emit('error', err); - rwatcher.on('all', function(evt, path, old){ - var outEvt = {type: evt, path: path}; - if(old) outEvt.old = old; - out.emit('change', outEvt); - if(cb) cb(outEvt); - }); - }); - - watcher.on('end', out.emit.bind(out, 'end')); - watcher.on('error', out.emit.bind(out, 'error')); - watcher.on('ready', out.emit.bind(out, 'ready')); - watcher.on('nomatch', out.emit.bind(out, 'nomatch')); - - out.end = function(){ - return watcher.close(); - }; - out.add = function(){ - return watcher.add.apply(watcher, arguments); - }; - out.remove = function(){ - return watcher.remove(); - }; - out._watcher = watcher; - - return out; -}; diff --git a/node_modules/glob-watcher/package.json b/node_modules/glob-watcher/package.json deleted file mode 100644 index 613505cd8..000000000 --- a/node_modules/glob-watcher/package.json +++ /dev/null @@ -1,35 +0,0 @@ -{ - "name": "glob-watcher", - "description": "Watch globs", - "version": "0.0.6", - "homepage": "http://github.com/wearefractal/glob-watcher", - "repository": "git://github.com/wearefractal/glob-watcher.git", - "author": "Fractal <contact@wearefractal.com> (http://wearefractal.com/)", - "main": "./index.js", - "dependencies": { - "gaze": "^0.5.1" - }, - "devDependencies": { - "mocha": "^1.17.0", - "should": "^2.1.1", - "mocha-lcov-reporter": "0.0.1", - "coveralls": "^2.6.1", - "istanbul": "^0.2.3", - "rimraf": "^2.2.5", - "jshint": "^2.4.1", - "mkdirp": "^0.3.5" - }, - "scripts": { - "test": "mocha --reporter spec && jshint", - "coveralls": "istanbul cover _mocha --report lcovonly -- -R spec && cat ./coverage/lcov.info | coveralls && rm -rf ./coverage" - }, - "engines": { - "node": ">= 0.9" - }, - "licenses": [ - { - "type": "MIT", - "url": "http://github.com/wearefractal/glob-watcher/raw/master/LICENSE" - } - ] -} diff --git a/node_modules/glob-watcher/test/fixtures/test.coffee b/node_modules/glob-watcher/test/fixtures/test.coffee deleted file mode 100644 index 4be3c4508..000000000 --- a/node_modules/glob-watcher/test/fixtures/test.coffee +++ /dev/null @@ -1 +0,0 @@ -test test
\ No newline at end of file diff --git a/node_modules/glob-watcher/test/main.js b/node_modules/glob-watcher/test/main.js deleted file mode 100644 index 2903e8f8a..000000000 --- a/node_modules/glob-watcher/test/main.js +++ /dev/null @@ -1,87 +0,0 @@ -var watch = require('../'); -var should = require('should'); -var path = require('path'); -var fs = require('fs'); -var rimraf = require('rimraf'); -var mkdirp = require('mkdirp'); - -require('mocha'); - -describe('glob-watcher', function() { - it('should return a valid file struct via EE', function(done) { - var expectedName = path.join(__dirname, "./fixtures/stuff/temp.coffee"); - var fname = path.join(__dirname, "./fixtures/**/temp.coffee"); - mkdirp.sync(path.dirname(expectedName)); - fs.writeFileSync(expectedName, "testing"); - - var watcher = watch(fname); - watcher.on('change', function(evt) { - should.exist(evt); - should.exist(evt.path); - should.exist(evt.type); - evt.type.should.equal('changed'); - evt.path.should.equal(expectedName); - watcher.end(); - }); - watcher.on('end', function(){ - rimraf.sync(expectedName); - done(); - }); - setTimeout(function(){ - fs.writeFileSync(expectedName, "test test"); - }, 125); - }); - - it('should emit nomatch via EE', function(done) { - var fname = path.join(__dirname, "./doesnt_exist_lol/temp.coffee"); - - var watcher = watch(fname); - watcher.on('nomatch', function() { - done(); - }); - }); - - it('should return a valid file struct via callback', function(done) { - var expectedName = path.join(__dirname, "./fixtures/stuff/test.coffee"); - var fname = path.join(__dirname, "./fixtures/**/test.coffee"); - mkdirp.sync(path.dirname(expectedName)); - fs.writeFileSync(expectedName, "testing"); - - var watcher = watch(fname, function(evt) { - should.exist(evt); - should.exist(evt.path); - should.exist(evt.type); - evt.type.should.equal('changed'); - evt.path.should.equal(expectedName); - watcher.end(); - }); - - watcher.on('end', function(){ - rimraf.sync(expectedName); - done(); - }); - setTimeout(function(){ - fs.writeFileSync(expectedName, "test test"); - }, 200); - }); - - it('should not return a non-matching file struct via callback', function(done) { - var expectedName = path.join(__dirname, "./fixtures/test123.coffee"); - var fname = path.join(__dirname, "./fixtures/**/test.coffee"); - mkdirp.sync(path.dirname(expectedName)); - fs.writeFileSync(expectedName, "testing"); - - var watcher = watch(fname, function(evt) { - throw new Error("Should not have been called! "+evt.path); - }); - - setTimeout(function(){ - fs.writeFileSync(expectedName, "test test"); - }, 200); - - setTimeout(function(){ - rimraf.sync(expectedName); - done(); - }, 1500); - }); -});
\ No newline at end of file |