File tree Expand file tree Collapse file tree 2 files changed +410
-1
lines changed Expand file tree Collapse file tree 2 files changed +410
-1
lines changed Original file line number Diff line number Diff line change @@ -294,7 +294,17 @@ function* forEachWildcardEntry(
294
294
let valueDirectoryFullPath = path . join ( cwd , valueDirectoryName ) ;
295
295
296
296
if ( existsSync ( valueDirectoryFullPath ) ) {
297
- let filesInDirectory = readdirSync ( valueDirectoryFullPath ) . filter (
297
+ let directoryContents = readdirSync ( valueDirectoryFullPath ) ;
298
+ let directoriesInDirectory = directoryContents . filter (
299
+ ( filepath ) => statSync ( path . join ( valueDirectoryFullPath , filepath ) ) . isDirectory ( ) , // ignore directories
300
+ ) ;
301
+
302
+ for ( let directoryname of directoriesInDirectory ) {
303
+ const nextdir = `${ valueDirectoryName } /${ directoryname } /*` ;
304
+ yield * forEachWildcardEntry ( nextdir , nextdir , cwd ) ;
305
+ }
306
+
307
+ let filesInDirectory = directoryContents . filter (
298
308
( filepath ) => statSync ( path . join ( valueDirectoryFullPath , filepath ) ) . isFile ( ) , // ignore directories
299
309
) ;
300
310
You can’t perform that action at this time.
0 commit comments