publish-to-pypi.yml 586 B

123456789101112131415161718192021222324
  1. name: deploy
  2. on: push
  3. concurrency:
  4. group: ${{ github.workflow }}-${{ github.ref }}
  5. cancel-in-progress: true
  6. jobs:
  7. deploy:
  8. runs-on: ubuntu-18.04
  9. if: startsWith(github.event.ref, 'refs/tags')
  10. steps:
  11. - uses: actions/checkout@v2
  12. - name: Set up Python 3.7
  13. uses: actions/setup-python@v1
  14. with:
  15. python-version: 3.7
  16. - name: Build MIM
  17. run: python setup.py sdist
  18. - name: Publish distribution to PyPI
  19. run: |
  20. pip install twine
  21. twine upload dist/* -u __token__ -p ${{ secrets.pypi_password }}