Prepare 0.7.0 release #10
Workflow file for this run
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| name: Master Deploy | |
| on: | |
| push: | |
| tags: | |
| - 'v*' | |
| jobs: | |
| coverage: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v3 | |
| with: | |
| fetch-depth: 0 | |
| - name: Setup environment (coverage) | |
| uses: ./.github/actions/setup-env | |
| with: | |
| python-version: "3.10" | |
| install-flags: "--all-extras" | |
| - name: Run tests with coverage | |
| run: | | |
| poetry run coverage run -m pytest | |
| poetry run coverage report | |
| poetry run coverage xml | |
| - name: Upload coverage to Codecov | |
| env: | |
| CODECOV_TOKEN: ${{ secrets.CODECOV_TOKEN }} | |
| run: bash <(curl -s https://codecov.io/bash) -t $CODECOV_TOKEN -f coverage.xml | |
| deploy-prod: | |
| needs: coverage | |
| runs-on: ubuntu-latest | |
| env: | |
| POETRY_PYPI_TOKEN_PYPI: ${{ secrets.PYPI_API_TOKEN }} | |
| steps: | |
| - uses: actions/checkout@v3 | |
| with: | |
| fetch-depth: 0 | |
| - name: Setup environment (deploy) | |
| uses: ./.github/actions/setup-env | |
| with: | |
| python-version: "3.10" | |
| install-flags: "--all-extras" | |
| - name: Configure PyPI | |
| run: | | |
| poetry config repositories.pypi https://upload.pypi.org/legacy/ | |
| poetry config pypi-token.pypi $POETRY_PYPI_TOKEN_PYPI | |
| - name: Publish to PyPI | |
| run: | | |
| poetry build | |
| poetry publish |