/ Published in: Python

Expand |
Embed | Plain Text
Copy this code and paste it in your HTML
def shell(*cmd): pipe = subprocess.Popen(cmd, stdout=subprocess.PIPE, stderr=subprocess.PIPE) stdout, stderr = pipe.communicate() return pipe.returncode, stdout, stderr
Comments
