Skip to content

Commit 5a51920

Browse files
committed
[ci] simplify pypi upload
1 parent 314deb1 commit 5a51920

File tree

1 file changed

+4
-20
lines changed

1 file changed

+4
-20
lines changed

.github/workflows/build_all.yml

Lines changed: 4 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -38,8 +38,7 @@ jobs:
3838
build_noarch_wheels:
3939
name: Build iso2mesh wheels
4040
runs-on: ubuntu-22.04
41-
outputs:
42-
perform_pypi_upload: ${{ steps.perform_pypi_upload_check.outputs.perform_pypi_upload }}
41+
needs: run_unit_test
4342
steps:
4443
- name: Checkout repo
4544
uses: actions/checkout@v3
@@ -51,27 +50,12 @@ jobs:
5150
run: python3 -m build
5251
- name: Check If the Build Version Exists on PyPI
5352
id: perform_pypi_upload_check
53+
shell: bash
5454
run: |
55-
bash $GITHUB_WORKSPACE/.github/check-pypi-upload.sh
56-
- name: Prepare Wheels for Upload
57-
uses: actions/upload-artifact@v4
58-
with:
59-
name: noarch-wheels-${{ matrix.python_version }}
60-
path: dist/
61-
62-
upload_noarch_wheels:
63-
needs: build_noarch_wheels
64-
runs-on: ubuntu-22.04
65-
if: ${{ github.repository_owner == 'fangq' && needs.build_noarch_wheels.outputs.perform_pypi_upload == 1 && github.event_name != 'pull_request'}}
66-
steps:
67-
- name: Download Wheels from Build Job
68-
uses: actions/download-artifact@v4
69-
with:
70-
pattern: noarch-wheels-*
71-
merge-multiple: true
72-
path: dist/
55+
$GITHUB_WORKSPACE/.github/check-pypi-upload.sh
7356
- name: Upload packages to PyPI
7457
uses: pypa/gh-action-pypi-publish@release/v1
58+
if: ${{ github.repository_owner == 'fangq' && steps.perform_pypi_upload_check.outputs.perform_pypi_upload == 1 && github.event_name != 'pull_request'}}
7559
with:
7660
password: ${{ secrets.PYPI_API_TOKEN }}
7761
verify_metadata: false

0 commit comments

Comments
 (0)