aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authoragronholm <none@none>2009-09-23 03:10:40 +0300
committeragronholm <none@none>2009-09-23 03:10:40 +0300
commit269f12efa9ac5640bb9ad4a79c26e77c66f1a950 (patch)
treef68ed2895949ec5d85b5d6021b846da75c370a76
parent2e5e7b750801a07eed519303d95799f0760b576b (diff)
downloadexternal_python_setuptools-269f12efa9ac5640bb9ad4a79c26e77c66f1a950.tar.gz
external_python_setuptools-269f12efa9ac5640bb9ad4a79c26e77c66f1a950.tar.bz2
external_python_setuptools-269f12efa9ac5640bb9ad4a79c26e77c66f1a950.zip
Fix python_cmd return value
--HG-- branch : distribute extra : rebase_source : 09f20b70ead91373507168c66a1f709a4eaba4f5
-rw-r--r--distribute_setup.py16
1 files changed, 4 insertions, 12 deletions
diff --git a/distribute_setup.py b/distribute_setup.py
index 83686932..e099b37b 100644
--- a/distribute_setup.py
+++ b/distribute_setup.py
@@ -43,17 +43,9 @@ Description: xxx
"""
-def quote(c):
- if sys.platform == 'win32':
- if ' ' in c:
- return '"%s"' % c
- return c
-
-
-def python_cmd(cmd):
- python = quote(sys.executable)
- cmd = quote(cmd)
- return subprocess.call([python, cmd])
+def python_cmd(*args):
+ args = (sys.executable,) + args
+ return subprocess.call(args) == 0
def _install(tarball):
@@ -74,7 +66,7 @@ def _install(tarball):
# installing
log.warn('Installing Distribute')
- assert python_cmd('setup.py install')
+ assert python_cmd('setup.py', 'install')
finally:
os.chdir(old_wd)