fix NPE
fix glob

Previous pattern failed on Mac
-
-
error context
Make listDir breadth-first
Added "actions" and changed main