build: use newer convention when building for release

This commit is contained in:
Lance Edgar 2024-06-10 15:57:09 -05:00
parent 04948fb840
commit 40e647d5c8

View file

@ -50,6 +50,7 @@ def release(c):
"""
Release a new version of 'pyCOREPOS'.
"""
shutil.rmtree('pyCOREPOS.egg-info')
c.run('python setup.py sdist --formats=gztar')
if os.path.exists('pyCOREPOS.egg-info'):
shutil.rmtree('pyCOREPOS.egg-info')
c.run('python -m build --sdist')
c.run('twine upload dist/pycorepos-{}.tar.gz'.format(__version__))