gradle #252
13
build.gradle
13
build.gradle
@ -183,7 +183,12 @@ def serverStart(String serverName) {
|
|||||||
writer = proc.getOutputStream().newWriter()
|
writer = proc.getOutputStream().newWriter()
|
||||||
writer.write("stop\n")
|
writer.write("stop\n")
|
||||||
writer.flush()
|
writer.flush()
|
||||||
|
awaitClose(proc, outputThread, inputThread)
|
||||||
|
}
|
||||||
|
awaitClose(proc, outputThread, inputThread)
|
||||||
|
}
|
||||||
|
|
||||||
|
private static def awaitClose(Process proc, Thread outputThread, Thread inputThread) {
|
||||||
while (proc.alive) {
|
while (proc.alive) {
|
||||||
Thread.sleep(10)
|
Thread.sleep(10)
|
||||||
}
|
}
|
||||||
@ -192,14 +197,6 @@ def serverStart(String serverName) {
|
|||||||
inputThread.interrupt()
|
inputThread.interrupt()
|
||||||
}
|
}
|
||||||
|
|
||||||
while (proc.alive) {
|
|
||||||
Thread.sleep(10)
|
|
||||||
}
|
|
||||||
|
|
||||||
outputThread.interrupt()
|
|
||||||
inputThread.interrupt()
|
|
||||||
}
|
|
||||||
|
|
||||||
def answer(String question) {
|
def answer(String question) {
|
||||||
while (System.in.available() > 0) System.in.read()
|
while (System.in.available() > 0) System.in.read()
|
||||||
println(question)
|
println(question)
|
||||||
|
In neuem Issue referenzieren
Einen Benutzer sperren