Skip to content
Snippets Groups Projects
run_command_bash.py 270 B
import subprocess


class RunCommandBash:
    def __init__(self, cmd, args):
        self.cmd = cmd
        self.args = args

    def __call__(self):
        print("Running command: " + self.cmd + " " + " ".join(self.args))
        subprocess.run([self.cmd, *self.args])