]>
git.immae.eu Git - perso/Immae/Projets/Python/MusicSampler.git/blob - music_sampler/actions/run_command.py
1 import shlex
, subprocess
3 def run(action
, command
="", wait
=False, **kwargs
):
4 action
.process
= subprocess
.Popen(command
, shell
=True)
8 def description(action
, command
="", wait
=False, **kwargs
):
10 message
= "running command {}"
11 formats
.append(command
)
13 message
+= " (waiting for its execution to finish)"
15 return _(message
).format(*formats
)