mirror of
https://github.com/ethauvin/kobalt.git
synced 2025-04-26 00:17:11 -07:00
Always compile the build files with Kotlin incremental compilation disabled.
This commit is contained in:
parent
187593b9b1
commit
1f3f666d93
6 changed files with 23 additions and 8 deletions
|
@ -19,7 +19,6 @@ import java.io.File
|
|||
class KobaltContext(val args: Args) {
|
||||
lateinit var variant: Variant
|
||||
val profiles = arrayListOf<String>()
|
||||
var forceRecompile: Boolean = false
|
||||
|
||||
init {
|
||||
args.profiles?.split(',')?.filterNotNull()?.forEach {
|
||||
|
@ -106,4 +105,12 @@ class InternalContext {
|
|||
* The absolute directory of the current project.
|
||||
*/
|
||||
var absoluteDir: File? = null
|
||||
|
||||
/**
|
||||
* If true, will force a recompile of the files even if using the incremental compile
|
||||
*/
|
||||
var forceRecompile: Boolean = false
|
||||
|
||||
var noIncrementalKotlin: Boolean = false
|
||||
|
||||
}
|
|
@ -167,7 +167,7 @@ class CompilerUtils @Inject constructor(val files: KFiles, val dependencyManager
|
|||
// Finally, alter the info with the compiler interceptors before returning it
|
||||
val initialActionInfo = CompilerActionInfo(projectDirectory.path, classpath, allSources,
|
||||
sourceSuffixes, buildDirectory, emptyList() /* the flags will be provided by flag contributors */,
|
||||
emptyList(), context.forceRecompile)
|
||||
emptyList(), context.internalContext.forceRecompile)
|
||||
val result = context.pluginInfo.compilerInterceptors.fold(initialActionInfo, { ai, interceptor ->
|
||||
interceptor.intercept(project, context, ai)
|
||||
})
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue