~naglis/aio_mpv_ipc

50726e50e2c163e9ae178edc0ad275bcd5de324c — Naglis Jonaitis 11 months ago 6f7abfa
Add publish workflow
2 files changed, 32 insertions(+), 0 deletions(-)

A .github/workflows/publish.yml
A scripts/ci/publish.sh
A .github/workflows/publish.yml => .github/workflows/publish.yml +25 -0
@@ 0,0 1,25 @@
name: Publish on PyPI
on:
  push:
    tags:
      - '*'
jobs:
  publish:
    runs-on: ubuntu-18.04
    steps:
      - uses: actions/checkout@v2
      - name: Set up Python 3.8
        uses: actions/setup-python@v2
        with:
          python-version: 3.8
      - name: Install
        run: scripts/ci/install.sh
      - name: Test
        run: scripts/ci/test.sh
      - name: Lint
        run: scripts/ci/lint.sh
      - name: Publish package on PyPI
        env:
          PYPI_USERNAME: ${{ secrets.PYPI_USERNAME }}
          PYPI_PASSWORD: ${{ secrets.PYPI_PASSWORD }}
        run: scripts/ci/publish.sh

A scripts/ci/publish.sh => scripts/ci/publish.sh +7 -0
@@ 0,0 1,7 @@
#!/usr/bin/env bash
set -euxo pipefail

source $HOME/.poetry/env

poetry build --format wheel
poetry publish --username ${PYPI_USERNAME} --password ${PYPI_PASSWORD}