This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var fs = require('fs'), | |
walk = require('walk'), | |
path = require('path'), | |
mm = require('musicmetadata'); | |
walker = walk.walk('/Users/leetreveil/Music/Mine', { followLinks : false }); | |
walker.on('file', function(root, fileStats, next) { | |
if (/^.*\.(mp3|m4a|flac|ogg)/.test(fileStats.name)) { | |
var fullPath = path.join(root, fileStats.name); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
processor.emit = function() { | |
var event = arguments[0]; | |
var value = arguments[1]; | |
//emit original event | |
self.emit(event, value); | |
//rewrite to new alias | |
for(var i in MAPPINGS){ | |
var current = MAPPINGS[i]; | |
if(current.from.indexOf(event) > -1){ |
NewerOlder