aboutsummaryrefslogtreecommitdiff
path: root/wqflask/utility/external.py
diff options
context:
space:
mode:
authorzsloan2016-05-17 16:03:05 +0000
committerzsloan2016-05-17 16:03:05 +0000
commit0d590051ce073a169295382e5adac34cc803e5ac (patch)
tree76bea6f1f69288a498e9f13d20b638b942ab0a0c /wqflask/utility/external.py
parentf6cee1731772c3482b0afd4c77472d69e747c655 (diff)
parent04afa563e6d53fe2a91ac2e6eb4af2f2fa5d5c3b (diff)
downloadgenenetwork2-0d590051ce073a169295382e5adac34cc803e5ac.tar.gz
Merge branch 'staging' of github.com:genenetwork/genenetwork2
Diffstat (limited to 'wqflask/utility/external.py')
-rw-r--r--wqflask/utility/external.py9
1 files changed, 9 insertions, 0 deletions
diff --git a/wqflask/utility/external.py b/wqflask/utility/external.py
new file mode 100644
index 00000000..50afea08
--- /dev/null
+++ b/wqflask/utility/external.py
@@ -0,0 +1,9 @@
+# Call external program
+
+import os
+import sys
+import subprocess
+
+def shell(command):
+ if subprocess.call(command, shell=True) != 0:
+ raise Exception("ERROR: failed on "+command)