diff --git a/.github/workflows/run.yml b/.github/workflows/run.yml index 243b3db..b0ea5ff 100644 --- a/.github/workflows/run.yml +++ b/.github/workflows/run.yml @@ -31,17 +31,27 @@ jobs: runs-on: ubuntu-latest steps: - uses: actions/checkout@v2 + - name: Check For Version Tag + id: check-tag + run: | + if [[ ${{ github.event.ref }} =~ ^refs/tags/v[0-9]+\.[0-9]+\.[0-9]+$ ]]; then + echo ::set-output name=match::true + fi - name: Set up Python + if: steps.check-tag.outputs.match == 'true' uses: actions/setup-python@v2 with: python-version: 3.8 - name: Install Packaging Tools + if: steps.check-tag.outputs.match == 'true' run: | make package.install - name: Build Package + if: steps.check-tag.outputs.match == 'true' run: | make package.build - - name: Publish package to TestPyPi + - name: Publish package to PyPi + if: steps.check-tag.outputs.match == 'true' uses: pypa/gh-action-pypi-publish@release/v1 with: user: __token__