Skip to content

Commit

Permalink
Merge pull request #280 from cta-observatory/fix_deploy
Browse files Browse the repository at this point in the history
Fix download of artifacts in deploy step
  • Loading branch information
maxnoe committed Jul 16, 2024
2 parents 7aabe1c + c7c0e83 commit 79228db
Showing 1 changed file with 11 additions and 8 deletions.
19 changes: 11 additions & 8 deletions .github/workflows/deploy.yml
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ jobs:
- uses: actions/upload-artifact@v4
with:
path: ./dist/*.whl
name: wheels-${{ matrix.os }}
name: dist-wheels-${{ matrix.os }}-${{ strategy.job-index }}

build_sdist:
runs-on: ubuntu-latest
Expand All @@ -63,23 +63,26 @@ jobs:
- uses: actions/upload-artifact@v4
with:
path: ./dist/*.tar.gz
name: sdist
name: dist-sdist

pypi_upload:
if: startsWith(github.ref, 'refs/tags/v')
if: github.event_name == 'push' && startsWith(github.ref, 'refs/tags/v')
runs-on: ubuntu-latest
needs:
- build_wheels
- build_sdist
steps:
- name: Download artifacts
uses: actions/download-artifact@v4
with:
# unpacks all dist artifacts into dist/
pattern: dist-*
path: dist
merge-multiple: true

- name: preparing upload
run: |
ls -l wheels sdist
mkdir dist
cp wheels/* sdist/* dist/

- name: Check files
run: ls -l dist

- name: Publish package
uses: pypa/gh-action-pypi-publish@release/v1
Expand Down

0 comments on commit 79228db

Please sign in to comment.