Skip to content

Commit 42a98f8

Browse files
committed
CI: Duplicate check for build & deploy
1 parent eb8054a commit 42a98f8

File tree

1 file changed

+2
-4
lines changed

1 file changed

+2
-4
lines changed

Diff for: .github/workflows/test_and_distribute.yml

+2-4
Original file line numberDiff line numberDiff line change
@@ -12,8 +12,6 @@ jobs:
1212
env:
1313
# The Python version from the matrix used to build and deploy to Pypi
1414
PYTHON_BUILD_VERSION: 3.8
15-
# Condition for building and deploying
16-
BUILD_AND_DEPLOY: ${{ github.event_name == 'push' && matrix.python-version == $PYTHON_BUILD_VERSION }}
1715
steps:
1816
- uses: actions/checkout@v2
1917
- name: Set up Python ${{ matrix.python-version }}
@@ -36,11 +34,11 @@ jobs:
3634
run: |
3735
python -m unittest discover
3836
- name: Build package with Python ${{ env.PYTHON_BUILD_VERSION }}
39-
if: ${{ env.BUILD_AND_DEPLOY }}
37+
if: ${{ github.event_name == 'push' && matrix.python-version == env.PYTHON_BUILD_VERSION }}
4038
run: python -m build
4139
# - name: Publish package relying on pypa/gh-action-pypi-publish with Python ${{ env.PYTHON_BUILD_VERSION }}
4240
# uses: pypa/gh-action-pypi-publish@27b31702a0e7fc50959f5ad993c78deac1bdfc29
43-
# if: ${{ env.BUILD_AND_DEPLOY }}
41+
# if: ${{ github.event_name == 'push' && matrix.python-version == env.PYTHON_BUILD_VERSION }}
4442
# with:
4543
# user: __token__
4644
# password: ${{ secrets.PYPI_API_TOKEN }}

0 commit comments

Comments
 (0)