python-boto3/scripts/ci/install

23 lines
535 B
Plaintext
Raw Normal View History

2015-11-27 23:25:33 +01:00
#!/usr/bin/env python
import os
import sys
from subprocess import check_call
import shutil
_dname = os.path.dirname
REPO_ROOT = _dname(_dname(_dname(os.path.abspath(__file__))))
os.chdir(REPO_ROOT)
def run(command):
return check_call(command, shell=True)
run('pip install -r requirements.txt')
run('pip install coverage')
if os.path.isdir('dist') and os.listdir('dist'):
shutil.rmtree('dist')
run('python setup.py bdist_wheel')
wheel_dist = os.listdir('dist')[0]
run('pip install %s' % (os.path.join('dist', wheel_dist)))