From eb80db4bc68b5a4bf2bf73dc00745ea82def8f03 Mon Sep 17 00:00:00 2001 From: Dmitry Shutov Date: Mon, 9 Jan 2023 15:14:46 +0600 Subject: [PATCH] Setup publish action --- .github/workflows/publish.yaml | 27 +++++++++++++++++++++++++++ 1 file changed, 27 insertions(+) create mode 100644 .github/workflows/publish.yaml diff --git a/.github/workflows/publish.yaml b/.github/workflows/publish.yaml new file mode 100644 index 0000000..bea332c --- /dev/null +++ b/.github/workflows/publish.yaml @@ -0,0 +1,27 @@ +name: Publish to https://pypi.org/ + +on: + release: + types: [created] + +jobs: + build: + runs-on: ubuntu-latest + permissions: + packages: write + contents: read + steps: + - uses: actions/checkout@v3 + - name: Set up Python 3.11 + uses: actions/setup-python@v3 + with: + python-version: "3.11" + - name: Install wheel and build + run: pip install wheel build + - name: Build a binary wheel and a source tarball + run: python -m build + - name: Publish package + uses: pypa/gh-action-pypi-publish@release/v1 + with: + user: __token__ + password: ${{ secrets.PYPI_API_TOKEN }}