Set idea.io.use.nio2=true every build on windows
Otherwise (setting property once in static block) gradle daemon might clear system properties
#KT-11770 fixed
This commit is contained in:
@@ -49,7 +49,7 @@ import java.util.Properties;
|
|||||||
import static org.jetbrains.kotlin.cli.common.ExitCode.*;
|
import static org.jetbrains.kotlin.cli.common.ExitCode.*;
|
||||||
|
|
||||||
public abstract class CLICompiler<A extends CommonCompilerArguments> {
|
public abstract class CLICompiler<A extends CommonCompilerArguments> {
|
||||||
static {
|
static private void setIdeaIoUseFallback() {
|
||||||
if (SystemInfo.isWindows) {
|
if (SystemInfo.isWindows) {
|
||||||
Properties properties = System.getProperties();
|
Properties properties = System.getProperties();
|
||||||
|
|
||||||
@@ -202,6 +202,7 @@ public abstract class CLICompiler<A extends CommonCompilerArguments> {
|
|||||||
}
|
}
|
||||||
Disposable rootDisposable = Disposer.newDisposable();
|
Disposable rootDisposable = Disposer.newDisposable();
|
||||||
try {
|
try {
|
||||||
|
setIdeaIoUseFallback();
|
||||||
ExitCode code = doExecute(arguments, configuration, rootDisposable);
|
ExitCode code = doExecute(arguments, configuration, rootDisposable);
|
||||||
exitCode = groupingCollector.hasErrors() ? COMPILATION_ERROR : code;
|
exitCode = groupingCollector.hasErrors() ? COMPILATION_ERROR : code;
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user