mirror of
https://github.com/freedomofpress/dangerzone.git
synced 2025-04-28 18:02:38 +02:00
Display command being executed in each task
This commit is contained in:
parent
2efde47ac4
commit
e1d0163504
1 changed files with 6 additions and 2 deletions
|
@ -2,6 +2,7 @@ import subprocess
|
||||||
import time
|
import time
|
||||||
import tempfile
|
import tempfile
|
||||||
import os
|
import os
|
||||||
|
import pipes
|
||||||
from PyQt5 import QtCore, QtWidgets, QtGui
|
from PyQt5 import QtCore, QtWidgets, QtGui
|
||||||
|
|
||||||
|
|
||||||
|
@ -15,8 +16,11 @@ class TaskBase(QtCore.QThread):
|
||||||
super(TaskBase, self).__init__()
|
super(TaskBase, self).__init__()
|
||||||
|
|
||||||
def execute_podman(self, args, watch="stdout"):
|
def execute_podman(self, args, watch="stdout"):
|
||||||
print(f"Executing: {' '.join(args)}")
|
args_str = " ".join(pipes.quote(s) for s in args)
|
||||||
output = ""
|
print(f"Executing: {args_str}")
|
||||||
|
output = f"Executing: {args_str}\n\n"
|
||||||
|
self.update_details.emit(output)
|
||||||
|
|
||||||
with subprocess.Popen(
|
with subprocess.Popen(
|
||||||
args,
|
args,
|
||||||
stdin=None,
|
stdin=None,
|
||||||
|
|
Loading…
Reference in a new issue