See More

--- name: Python package # yamllint disable-line rule:truthy on: [push, pull_request] jobs: test: runs-on: ${{matrix.os}} strategy: max-parallel: 4 matrix: python-version: [3.6, 3.7, 3.8, 3.9, "3.x"] os: [ubuntu-latest, macos-latest] steps: - uses: actions/checkout@v1 - name: Set up Python ${{ matrix.python-version }} uses: actions/setup-python@v1 with: python-version: ${{ matrix.python-version }} - name: Install dependencies run: | python -m pip install --upgrade pip python -m pip install poetry poetry install --no-ansi - name: Test with pytest run: | poetry run pytest test-ppc: runs-on: ubuntu-18.04 name: Test for PPC steps: - uses: actions/checkout@v1 - uses: uraimo/[email protected] name: Run tests for PPC id: runcmd with: arch: ppc64le distro: alpine_latest run: | apk update apk add python3 build-base python3-dev libffi-dev apk add libressl-dev musl-dev python3 -m venv .venv ./.venv/bin/pip install -U pip wheel ./.venv/bin/pip install poetry ./.venv/bin/poetry install --no-ansi ./.venv/bin/poetry run pytest publish: needs: [test, test-ppc] runs-on: ubuntu-latest if: > github.event_name == 'push' && startsWith(github.event.ref, 'refs/tags') steps: - uses: actions/checkout@v1 - name: Build distribution run: | pip install wheel pip install poetry ~/.local/bin/poetry build - name: Publish package uses: pypa/gh-action-pypi-publish@e777b333 with: user: __token__ password: ${{ secrets.pypi_token }}