From fb48059ae9196f2ca7be017eef6c9beab5b24f97 Mon Sep 17 00:00:00 2001 From: Florian Bruhin Date: Fri, 14 Aug 2015 07:17:53 +0200 Subject: [PATCH] ci_install: Don't use os.system. --- scripts/dev/ci_install.py | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/scripts/dev/ci_install.py b/scripts/dev/ci_install.py index 9156518cc..f4ce47b4b 100644 --- a/scripts/dev/ci_install.py +++ b/scripts/dev/ci_install.py @@ -92,7 +92,6 @@ elif os.environ.get('TRAVIS_OS_NAME', None) == 'osx': check_setup('python3') - os.system('ls -l /usr/local/bin/xvfb-run') print("Creating xvfb-run stub...") with open('/usr/local/bin/xvfb-run', 'w') as f: # This will break when xvfb-run is called differently in .travis.yml, @@ -100,8 +99,7 @@ elif os.environ.get('TRAVIS_OS_NAME', None) == 'osx': f.write('#!/bin/bash\n') f.write('shift 2\n') f.write('exec "$@"\n') - os.system('sudo chmod 755 /usr/local/bin/xvfb-run') - os.system('ls -l /usr/local/bin/xvfb-run') + subprocess.check_call(['sudo', 'chmod', '755', '/usr/local/bin/xvfb-run']) else: def env(key): return os.environ.get(key, None)