$ ulimit -n 2048
Detailed info: http://otaqui.com/blog/1618/how-to-fix-error-emfile-too-many-open-files-from-yeoman-and-npm/
It happened to me when issued a brunch watch command from iTerm after doing it on RubyMine (w/ custom build command using brunch executable):