nl_tokens: List files and directories in a directory ( recursive ) . Warning : This recursive implementation is very costly .
pl_tokens: function readRecursive ( repoState , dirName ) { // TODO improve performance and don't use .read() directly const files = read ( repoState , dirName ) ; let filesInDirs = <mask> . filter ( ( file ) => { return file . isDirectory ( ) ; } ) . map ( ( dir ) => { return readRecursive ( repoState , dir . path ) ; } ) ; filesInDirs = flatten ( filesInDirs ) ; return Array . prototype . concat ( files , filesInDirs ) ; }