Run JS DCE gradle task in a separate process
This commit is contained in:
+9
-5
@@ -147,12 +147,16 @@ abstract class KotlinCompilerRunner<in Env : CompilerEnvironment> {
|
||||
environment: Env
|
||||
): ExitCode?
|
||||
|
||||
protected fun exitCodeFromProcessExitCode(code: Int): ExitCode {
|
||||
val exitCode = ExitCode.values().find { it.code == code }
|
||||
if (exitCode != null) return exitCode
|
||||
protected fun exitCodeFromProcessExitCode(code: Int): ExitCode = Companion.exitCodeFromProcessExitCode(log, code)
|
||||
|
||||
log.debug("Could not find exit code by value: $code")
|
||||
return if (code == 0) ExitCode.OK else ExitCode.COMPILATION_ERROR
|
||||
companion object {
|
||||
fun exitCodeFromProcessExitCode(log: KotlinLogger, code: Int): ExitCode {
|
||||
val exitCode = ExitCode.values().find { it.code == code }
|
||||
if (exitCode != null) return exitCode
|
||||
|
||||
log.debug("Could not find exit code by value: $code")
|
||||
return if (code == 0) ExitCode.OK else ExitCode.COMPILATION_ERROR
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user