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

Move buildDir to KFiles.

This commit is contained in:
Cedric Beust 2015-12-13 08:55:01 -08:00
parent 457de8de34
commit 421a5a6d4a
2 changed files with 4 additions and 4 deletions

View file

@ -66,6 +66,8 @@ class KFiles {
KFiles.joinDir(project.directory, project.buildDirectory, "generated", "source", name,
variant.toIntermediateDir())
fun buildDir(project: Project) = KFiles.makeDir(project.directory, project.buildDirectory)
/**
* Join the paths elements with the file separator.
*/

View file

@ -60,7 +60,7 @@ class PackagingPlugin @Inject constructor(val dependencyManager : DependencyMana
runTask = { taskAssemble(project) })
}
private fun libsDir(project: Project) = KFiles.makeDir(buildDir(project).path, "libs").path
private fun libsDir(project: Project) = KFiles.makeDir(KFiles.buildDir(project).path, "libs").path
@Task(name = TASK_ASSEMBLE, description = "Package the artifacts",
runAfter = arrayOf(JvmCompilerPlugin.TASK_COMPILE))
@ -125,7 +125,7 @@ class PackagingPlugin @Inject constructor(val dependencyManager : DependencyMana
//
// Add all the applicable files for the current project
//
val buildDir = buildDir(project)
val buildDir = KFiles.buildDir(project)
val allFiles = arrayListOf<IncludedFile>()
val classesDir = KFiles.makeDir(buildDir.path, "classes")
@ -189,8 +189,6 @@ class PackagingPlugin @Inject constructor(val dependencyManager : DependencyMana
true /* expandJarFiles */, jarFactory)
}
private fun buildDir(project: Project) = KFiles.makeDir(project.directory, project.buildDirectory)
private fun findIncludedFiles(directory: String, files: List<IncludedFile>, excludes: List<IFileSpec.Glob>)
: List<IncludedFile> {
val result = arrayListOf<IncludedFile>()