aboutsummaryrefslogtreecommitdiff
path: root/stage1/cbt.scala
diff options
context:
space:
mode:
Diffstat (limited to 'stage1/cbt.scala')
-rw-r--r--stage1/cbt.scala6
1 files changed, 6 insertions, 0 deletions
diff --git a/stage1/cbt.scala b/stage1/cbt.scala
index 8b6ebd8..5d2e2f5 100644
--- a/stage1/cbt.scala
+++ b/stage1/cbt.scala
@@ -28,6 +28,12 @@ object `package`{
def /(s: String): File = new File( file, s )
def parent = lib.realpath(file ++ "/..")
def string = file.toString
+
+ def listRecursive: Seq[File] = {
+ file +: (
+ if( file.isDirectory ) file.listFiles.flatMap(_.listRecursive).toVector else Seq[File]()
+ )
+ }
}
implicit class URLExtensionMethods( url: URL ){
def ++( s: String ): URL = new URL( url.toString ++ s )