lib/freeze.js
function freezeAllProcessDir(dir, basePath, result) {
    fs.readdirSync(dir).forEach(function(file) {
        file = PATH.resolve(dir, file);
        var stat = fs.statSync(file);
        if (stat.isFile()) {
            freezeAllProcessFile(file, basePath, result);

        } else if (stat.isDirectory()) {
            freezeAllProcessDir(file, basePath, result);
        }
    });
}
function freezeAllProcessDir(dir, basePath, result) {
    fs.readdirSync(dir).forEach(function(file) {
        file = PATH.resolve(dir, file);
        var stat = fs.statSync(file);
        if (stat.isFile()) {
            freezeAllProcessFile(file, basePath, result);

        } else if (stat.isDirectory()) {
            freezeAllProcessDir(file, basePath, result);
        }
    });
}
function freezeAllProcessDir ( dir , basePath , result ) { fs . readdirSync ( dir ) . forEach ( function ( file ) { file = PATH . resolve ( dir , file ) ; var stat = fs . statSync ( file ) ; if ( stat . isFile ( ) ) { freezeAllProcessFile ( file , basePath , result ) ; } else if ( stat . isDirectory ( ) ) { freezeAllProcessDir ( file , basePath , result ) ; } } ) ; }
Read dir recursivly and process files
@param dir
@param basePath
@param {Object} result Result JSON
Read dir recursivly and process files