| 54 | pass |
| 55 | |
| 56 | def run(self): |
| 57 | try: |
| 58 | self.status('Removing previous builds…') |
| 59 | rmtree(os.path.join(here, 'dist')) |
| 60 | except OSError: |
| 61 | pass |
| 62 | |
| 63 | self.status('Building Source and Wheel (universal) distribution…') |
| 64 | os.system('{0} setup.py sdist bdist_wheel --universal'.format(sys.executable)) |
| 65 | |
| 66 | self.status('Uploading the package to PyPi via Twine…') |
| 67 | os.system('twine upload dist/*') |
| 68 | |
| 69 | self.status('Publishing git tags…') |
| 70 | os.system('git tag v{0}'.format(VERSION)) |
| 71 | os.system('git push --tags') |
| 72 | |
| 73 | sys.exit() |
| 74 | |
| 75 | |
| 76 | # Where the magic happens: |