diff options
-rw-r--r-- | .github/workflows/build.yml | 20 | ||||
-rw-r--r-- | .github/workflows/main.yml | 33 |
2 files changed, 43 insertions, 10 deletions
diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 6255250d..be30b710 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -44,13 +44,13 @@ jobs: name: wheels path: dist - linters: - runs-on: ubuntu-latest - steps: - - uses: actions/checkout@v2 - - uses: actions/setup-python@v2 - - name: 'Run linters' - run: | - python3 -m pip install flake8 - python3 -m flake8 . - echo "Flake8 linting OK" + # linters: + # runs-on: ubuntu-latest + # steps: + # - uses: actions/checkout@v2 + # - uses: actions/setup-python@v2 + # - name: 'Run linters' + # run: | + # python3 -m pip install flake8 + # python3 -m flake8 . + # echo "Flake8 linting OK" diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index d58e3e41..d36e25f1 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -83,3 +83,36 @@ jobs: platforms: ${{env.DOCKER_PLATFORMS}} cache-from: type=local,src=/tmp/.buildx-cache cache-to: type=local,dest=/tmp/.buildx-cache,mode=max + + pypi: + runs-on: ubuntu-latest + steps: + + - name: Install pypa/build + run: >- + python -m + pip install + build + --user + + - name: Build a binary wheel and a source tarball + run: >- + python -m + build + --sdist + --wheel + --outdir dist/ + + - name: Publish distribution package to Test PyPI + uses: pypa/gh-action-pypi-publish@master + with: + user: ${{ secrets.PYPI_USERNAME }} + password: ${{ secrets.TEST_PYPI_API_TOKEN }} + repository_url: https://test.pypi.org/legacy/ + + - name: Publish distribution package to PyPI + if: startsWith(github.ref, 'refs/tags') + uses: pypa/gh-action-pypi-publish@master + with: + user: ${{ secrets.PYPI_USERNAME }} + password: ${{ secrets.PYPI_API_TOKEN }}
\ No newline at end of file |