File tree Expand file tree Collapse file tree 3 files changed +12
-3
lines changed
jvm-embeddable-host/src/main/kotlin/org/jetbrains/kotlin/script/examples/jvm/embeddable/host
jvm-maven-deps/host/src/main/kotlin/org/jetbrains/kotlin/script/examples/jvm/resolve/maven/host
jvm-simple-script/host/src/main/kotlin/org/jetbrains/kotlin/script/examples/jvm/simple/host Expand file tree Collapse file tree 3 files changed +12
-3
lines changed Original file line number Diff line number Diff line change @@ -8,6 +8,7 @@ import org.jetbrains.kotlin.script.examples.jvm.simple.SimpleScript
8
8
import java.io.File
9
9
import kotlin.script.experimental.api.EvaluationResult
10
10
import kotlin.script.experimental.api.ResultWithDiagnostics
11
+ import kotlin.script.experimental.api.ScriptDiagnostic
11
12
import kotlin.script.experimental.host.toScriptSource
12
13
import kotlin.script.experimental.jvm.dependenciesFromCurrentContext
13
14
import kotlin.script.experimental.jvm.jvm
@@ -38,7 +39,9 @@ fun main(vararg args: String) {
38
39
val res = evalFile(scriptFile)
39
40
40
41
res.reports.forEach {
41
- println (" : ${it.message} " + if (it.exception == null ) " " else " : ${it.exception} " )
42
+ if (it.severity > ScriptDiagnostic .Severity .DEBUG ) {
43
+ println (" : ${it.message} " + if (it.exception == null ) " " else " : ${it.exception} " )
44
+ }
42
45
}
43
46
}
44
47
}
Original file line number Diff line number Diff line change @@ -9,6 +9,7 @@ import org.jetbrains.kotlin.script.examples.jvm.resolve.maven.ScriptWithMavenDep
9
9
import java.io.File
10
10
import kotlin.script.experimental.api.EvaluationResult
11
11
import kotlin.script.experimental.api.ResultWithDiagnostics
12
+ import kotlin.script.experimental.api.ScriptDiagnostic
12
13
import kotlin.script.experimental.host.toScriptSource
13
14
import kotlin.script.experimental.jvmhost.BasicJvmScriptingHost
14
15
import kotlin.script.experimental.jvmhost.createJvmCompilationConfigurationFromTemplate
@@ -30,7 +31,9 @@ fun main(vararg args: String) {
30
31
val res = evalFile(scriptFile)
31
32
32
33
res.reports.forEach {
33
- println (" : ${it.message} " + if (it.exception == null ) " " else " : ${it.exception} " )
34
+ if (it.severity > ScriptDiagnostic .Severity .DEBUG ) {
35
+ println (" : ${it.message} " + if (it.exception == null ) " " else " : ${it.exception} " )
36
+ }
34
37
}
35
38
}
36
39
}
Original file line number Diff line number Diff line change @@ -9,6 +9,7 @@ import org.jetbrains.kotlin.script.examples.jvm.simple.SimpleScript
9
9
import java.io.File
10
10
import kotlin.script.experimental.api.EvaluationResult
11
11
import kotlin.script.experimental.api.ResultWithDiagnostics
12
+ import kotlin.script.experimental.api.ScriptDiagnostic
12
13
import kotlin.script.experimental.host.toScriptSource
13
14
import kotlin.script.experimental.jvm.dependenciesFromClassloader
14
15
import kotlin.script.experimental.jvm.dependenciesFromCurrentContext
@@ -49,7 +50,9 @@ fun main(vararg args: String) {
49
50
val res = evalFile(scriptFile)
50
51
51
52
res.reports.forEach {
52
- println (" : ${it.message} " + if (it.exception == null ) " " else " : ${it.exception} " )
53
+ if (it.severity > ScriptDiagnostic .Severity .DEBUG ) {
54
+ println (" : ${it.message} " + if (it.exception == null ) " " else " : ${it.exception} " )
55
+ }
53
56
}
54
57
}
55
58
}
You can’t perform that action at this time.
0 commit comments