add mouse cursor to screenshot

This commit is contained in:
Jing Hua
2023-11-30 17:31:46 +08:00
parent e52ba2ab13
commit ebb5f1cbc5
5 changed files with 37 additions and 7 deletions

View File

@@ -11,9 +11,11 @@ def execute_command():
# Execute the command without any safety checks.
try:
subprocess.run(command, shell=True, stdout=subprocess.PIPE, stderr=subprocess.PIPE)
result = subprocess.run(command, shell=True, stdout=subprocess.PIPE, stderr=subprocess.PIPE, text=True)
return jsonify({
'status': 'success',
'output': result.stdout,
'error': result.stderr
})
except Exception as e:
return jsonify({