lib/budo.js
function watch (glob, watchOpt) {
    if (!started) {
      deferredWatch = emitter.watch.bind(null, glob, watchOpt)
    } else {
      // destroy previous
      if (fileWatcher) fileWatcher.close()
      glob = glob && glob.length > 0 ? glob : defaultWatchGlob
      glob = Array.isArray(glob) ? glob : [ glob ]
      watchOpt = xtend({ poll: opts.poll }, watchOpt)

      fileWatcher = createFileWatch(glob, watchOpt)
      fileWatcher.on('watch', emitter.emit.bind(emitter, 'watch'))
    }
    return emitter
  }
function watch (glob, watchOpt) {
    if (!started) {
      deferredWatch = emitter.watch.bind(null, glob, watchOpt)
    } else {
      // destroy previous
      if (fileWatcher) fileWatcher.close()
      glob = glob && glob.length > 0 ? glob : defaultWatchGlob
      glob = Array.isArray(glob) ? glob : [ glob ]
      watchOpt = xtend({ poll: opts.poll }, watchOpt)

      fileWatcher = createFileWatch(glob, watchOpt)
      fileWatcher.on('watch', emitter.emit.bind(emitter, 'watch'))
    }
    return emitter
  }
function watch ( glob , watchOpt ) { if ( ! started ) { deferredWatch = emitter . watch . bind ( null , glob , watchOpt ) } else { // destroy previous if ( fileWatcher ) fileWatcher . close ( ) glob = glob && glob . length > 0 ? glob : defaultWatchGlob glob = Array . isArray ( glob ) ? glob : [ glob ] watchOpt = xtend ( { poll : opts . poll } , watchOpt ) fileWatcher = createFileWatch ( glob , watchOpt ) fileWatcher . on ( 'watch' , emitter . emit . bind ( emitter , 'watch' ) ) } return emitter }
enable file watch capabilities
enable file watch capabilities