feat: switch from setup.cfg to pyproject.toml + hatchling
This commit is contained in:
parent
2ab7cf04c6
commit
7089ced72b
6 changed files with 70 additions and 82 deletions
12
tasks.py
12
tasks.py
|
@ -30,17 +30,15 @@ import shutil
|
|||
from invoke import task
|
||||
|
||||
|
||||
here = os.path.abspath(os.path.dirname(__file__))
|
||||
exec(open(os.path.join(here, 'rattail_mailchimp', '_version.py')).read())
|
||||
|
||||
|
||||
@task
|
||||
def release(c):
|
||||
"""
|
||||
Release a new version of 'rattail-mailchimp'.
|
||||
"""
|
||||
shutil.rmtree('rattail_mailchimp.egg-info')
|
||||
if os.path.exists('dist'):
|
||||
shutil.rmtree('dist')
|
||||
if os.path.exists('rattail_mailchimp.egg-info'):
|
||||
shutil.rmtree('rattail_mailchimp.egg-info')
|
||||
c.run('python -m build --sdist')
|
||||
|
||||
filename = f'rattail_mailchimp-{__version__}.tar.gz'
|
||||
c.run('twine upload dist/{}'.format(filename))
|
||||
c.run('twine upload dist/*')
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue