styledocco
styledocco copied to clipboard
error when processing multiple sub directories
i'm not sure if there is a limit on depth or the number of sub folders but when processing a directory structure such as the following i get an error.
- less/
- base/
- (less files)
- components/
- sub-components/
- (less files)
- sub-components/
- pages/
- (less files)
- readme.md
- base/
child_process.js:794
throw errnoException(errno, 'spawn');
^
Error: spawn EMFILE
at errnoException (child_process.js:847:11)
at ChildProcess.spawn (child_process.js:794:11)
at exports.spawn (child_process.js:618:9)
at Object.exports.execFile (child_process.js:510:15)
at exports.exec (child_process.js:481:18)
at preprocess (/opt/local/lib/node_modules/styledocco/cli.js:110:5)
at Object.async.apply [as css] (/opt/local/lib/node_modules/styledocco/node_modules/async/lib/async.js:532:23)
at async.parallel (/opt/local/lib/node_modules/styledocco/node_modules/async/lib/async.js:467:25)
at async.forEach (/opt/local/lib/node_modules/styledocco/node_modules/async/lib/async.js:86:13)
at Array.forEach (native)
if i try and run styledocco on the folders separately it works fine, but when running the whole group it throws an error.
I would really like have all the docs generated at once
after some googling this seems to be caused by the os x ulimit on open files. I was able to avoid the error by setting the following ...
$ ulimit -n 1024
Ok, I should be able to fix this by setting a limit of how many files to process at once. Thanks for your report, I'll notify you when it's fixed
Aparently 256 is the default max number of files that can be opened at once.