2020-06-10 18:25:41 +02:00
|
|
|
extends Node2D
|
|
|
|
|
2020-09-01 15:14:01 +02:00
|
|
|
var thread
|
|
|
|
|
2020-09-01 14:03:18 +02:00
|
|
|
func send_command(command):
|
2020-09-01 15:14:01 +02:00
|
|
|
thread = Thread.new()
|
|
|
|
thread.start(self, "run_command_in_a_thread", command)
|
|
|
|
|
|
|
|
func run_command_in_a_thread(command):
|
2020-09-01 19:20:51 +02:00
|
|
|
var output = game.sh(command, "/tmp/active")
|
2020-09-01 14:03:18 +02:00
|
|
|
|
2020-08-24 16:48:30 +02:00
|
|
|
$Input.text = ""
|
2020-09-01 19:20:51 +02:00
|
|
|
$Output.text = $Output.text + "$ " + command + "\n" + output
|
2020-08-24 16:48:30 +02:00
|
|
|
$Output.scroll_vertical = 999999
|
2020-09-01 19:32:33 +02:00
|
|
|
$"../ActiveRepository".update_everything()
|