From f162d6ecf237dbae62a7d45aea74d683c36a84c6 Mon Sep 17 00:00:00 2001 From: Jonathan Chu Date: Thu, 29 Sep 2022 10:54:47 -0700 Subject: [PATCH] D Add GHA workflow for publishing to pypi --- .github/workflows/pypi.yaml | 28 ++++++++++++++++++++++++++++ 1 file changed, 28 insertions(+) create mode 100644 .github/workflows/pypi.yaml diff --git a/.github/workflows/pypi.yaml b/.github/workflows/pypi.yaml new file mode 100644 index 0000000..9633e2b --- /dev/null +++ b/.github/workflows/pypi.yaml @@ -0,0 +1,28 @@ +name: Publish on PyPI + +on: + push: + tags: + - v* + +jobs: + publish: + runs-on: ubuntu-latest + + steps: + - uses: actions/checkout@v3 + - uses: actions/setup-python@v4 + with: + python-version: 3.8 + + - name: Install Python dependencies + run: pip install wheel + + - name: Create a Wheel file and source distribution + run: python setup.py sdist bdist_wheel + + - name: Publish distribution package to PyPI + uses: pypa/gh-action-pypi-publish@v1.5.1 + with: + user: __token__ + password: ${{ secrets.PYPI_TOKEN }}