aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rwxr-xr-xmowgli.py5
1 files changed, 4 insertions, 1 deletions
diff --git a/mowgli.py b/mowgli.py
index 5cd4e91..c1b2dd3 100755
--- a/mowgli.py
+++ b/mowgli.py
@@ -128,7 +128,10 @@ def download(url):
def install(pkg):
- subprocess.call(['/usr/sbin/installer', '-pkg', pkg, '-target', '/'])
+ r = subprocess.call(['/usr/sbin/installer', '-pkg', pkg, '-target', '/'])
+ if r > 0:
+ raise Exception('Failed to install package %s' % pkg)
+
os.remove(pkg)