1
0
Fork 0
mirror of https://github.com/ethauvin/kobalt.git synced 2025-04-26 00:17:11 -07:00

/v1/getDependencyGraph?projectRoot=...

Deprecated buildFile=.
This commit is contained in:
Cedric Beust 2017-03-26 07:32:56 -07:00
parent 5c7d6a20cb
commit 043fc31c9f
4 changed files with 46 additions and 27 deletions

View file

@ -386,6 +386,19 @@ class KFiles {
return false
}
}
fun findBuildFile(projectRoot: String = "."): File {
val deprecatedLocation = File(Constants.BUILD_FILE_NAME)
val result: File =
if (deprecatedLocation.exists()) {
warn(Constants.BUILD_FILE_NAME + " is in a deprecated location, please move it to "
+ Constants.BUILD_FILE_DIRECTORY)
deprecatedLocation
} else {
File(KFiles.joinDir(projectRoot, Constants.BUILD_FILE_DIRECTORY, Constants.BUILD_FILE_NAME))
}
return result
}
}
fun findRecursively(directory: File, function: Function1<String, Boolean>): List<String> {