|
|
|
|
@ -1098,6 +1098,7 @@ if __name__ == "__main__":
|
|
|
|
|
try:
|
|
|
|
|
result = subprocess.run(query, capture_output=True, text=True, check=True)
|
|
|
|
|
print(f"Command run was: {query}")
|
|
|
|
|
print(result)
|
|
|
|
|
gui_status = result.stdout.strip()
|
|
|
|
|
print(f"Output of the command (stdout): {gui_status}")
|
|
|
|
|
except subprocess.CalledProcessError as e:
|
|
|
|
|
@ -1107,6 +1108,7 @@ if __name__ == "__main__":
|
|
|
|
|
print(f"Output of the command (stdout): {e.stdout}")
|
|
|
|
|
# print(f"Error output of the command (stderr): {e.stderr}")
|
|
|
|
|
if gui_status == "graphical.target":
|
|
|
|
|
print("Sleep another 30 seconds")
|
|
|
|
|
sleep(30) # sleep another 30 seconds for cpu to settle down
|
|
|
|
|
print (gui_status)
|
|
|
|
|
|
|
|
|
|
|