mirror of
https://github.com/ethauvin/kobalt.git
synced 2025-04-27 00:38:11 -07:00
Simplify.
This commit is contained in:
parent
c2e04ab8ce
commit
dec88149d9
2 changed files with 5 additions and 5 deletions
|
@ -21,10 +21,10 @@ class AndroidFiles {
|
||||||
return KFiles.joinDir(dir, "AndroidManifest.xml")
|
return KFiles.joinDir(dir, "AndroidManifest.xml")
|
||||||
}
|
}
|
||||||
|
|
||||||
fun mergedResourcesNoVariant(project: Project, variant: Variant) =
|
fun mergedResourcesNoVariant(project: Project) =
|
||||||
KFiles.joinAndMakeDir(AndroidFiles.intermediates(project), "res", "merged")
|
KFiles.joinAndMakeDir(AndroidFiles.intermediates(project), "res", "merged")
|
||||||
|
|
||||||
fun mergedResources(project: Project, variant: Variant) =
|
fun mergedResources(project: Project, variant: Variant) =
|
||||||
KFiles.joinAndMakeDir(mergedResourcesNoVariant(project, variant), variant.toIntermediateDir())
|
KFiles.joinAndMakeDir(mergedResourcesNoVariant(project), variant.toIntermediateDir())
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -15,7 +15,6 @@ import com.google.inject.Inject
|
||||||
import com.google.inject.Singleton
|
import com.google.inject.Singleton
|
||||||
import java.io.File
|
import java.io.File
|
||||||
import java.io.FileInputStream
|
import java.io.FileInputStream
|
||||||
import java.net.URI
|
|
||||||
import java.nio.file.Path
|
import java.nio.file.Path
|
||||||
import java.nio.file.Paths
|
import java.nio.file.Paths
|
||||||
|
|
||||||
|
@ -352,10 +351,11 @@ public class AndroidPlugin @Inject constructor(val javaCompiler: JavaCompiler, v
|
||||||
}
|
}
|
||||||
|
|
||||||
// IRepoContributor
|
// IRepoContributor
|
||||||
override fun reposFor(project: Project?): List<URI> {
|
override fun reposFor(project: Project?): List<HostInfo> {
|
||||||
val home = androidHomeNoThrows(project)
|
val home = androidHomeNoThrows(project)
|
||||||
return if (home != null) {
|
return if (home != null) {
|
||||||
listOf(Paths.get(KFiles.joinDir(home, "extras", "android", "m2repository")).toUri())
|
val path = Paths.get(KFiles.joinDir(home, "extras", "android", "m2repository"))
|
||||||
|
listOf(HostInfo(path.toUri().toString()))
|
||||||
} else {
|
} else {
|
||||||
emptyList()
|
emptyList()
|
||||||
}
|
}
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue