Skip to content

Commit

Permalink
Adjust upload/download artifact action
Browse files Browse the repository at this point in the history
Signed-off-by: Johannes Mueller <[email protected]>
  • Loading branch information
johannes-mueller committed Aug 1, 2024
1 parent 42bb773 commit df3dd63
Show file tree
Hide file tree
Showing 3 changed files with 40 additions and 16 deletions.
18 changes: 13 additions & 5 deletions .github/workflows/pypi-deploy-odbclient.yml
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
name: Build odbclient and upload to PyPI

on:
workflow_dispatch:
release:
types: [published]

Expand Down Expand Up @@ -30,6 +31,7 @@ jobs:
python setup.py bdist_wheel
- uses: actions/upload-artifact@v2
with:
name: artifact-wheel
path: tools/odbclient/dist/*.whl


Expand All @@ -55,6 +57,7 @@ jobs:

- uses: actions/upload-artifact@v4
with:
name: artifact-sdist
path: tools/odbclient/dist/*.tar.gz

upload_pypi:
Expand All @@ -64,12 +67,17 @@ jobs:
steps:
- uses: actions/download-artifact@v4
with:
name: artifact
name: artifact-sdist
path: dist

- uses: actions/download-artifact@v4
with:
name: artifact-wheel
path: dist

- uses: pypa/gh-action-pypi-publish@master
with:
user: __token__
password: ${{ secrets.upload_pypi }}
#password: ${{ secrets.test_pypi }}
#repository_url: https://test.pypi.org/legacy/
# user: __token__
# password: ${{ secrets.upload_pypi }}
password: ${{ secrets.test_pypi }}
repository_url: https://test.pypi.org/legacy/
18 changes: 13 additions & 5 deletions .github/workflows/pypi-deploy-odbserver.yml
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
name: Build odbserver and upload to PyPI

on:
workflow_dispatch:
release:
types: [published]

Expand Down Expand Up @@ -30,6 +31,7 @@ jobs:
python setup.py bdist_wheel
- uses: actions/upload-artifact@v4
with:
name: artifact-wheel
path: tools/odbserver/dist/*.whl


Expand All @@ -55,6 +57,7 @@ jobs:

- uses: actions/upload-artifact@v4
with:
name: artifact-sdist
path: tools/odbserver/dist/*.tar.gz

upload_pypi:
Expand All @@ -64,12 +67,17 @@ jobs:
steps:
- uses: actions/download-artifact@v4
with:
name: artifact
name: artifact-sdist
path: dist

- uses: actions/download-artifact@v4
with:
name: artifact-wheel
path: dist

- uses: pypa/gh-action-pypi-publish@master
with:
user: __token__
password: ${{ secrets.upload_pypi }}
#password: ${{ secrets.test_pypi }}
#repository_url: https://test.pypi.org/legacy/
# user: __token__
# password: ${{ secrets.upload_pypi }}
password: ${{ secrets.test_pypi }}
repository_url: https://test.pypi.org/legacy/
20 changes: 14 additions & 6 deletions .github/workflows/pypi-deploy.yml
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
name: Build and upload to PyPI

on:
workflow_dispatch:
release:
types: [published]

Expand Down Expand Up @@ -38,7 +39,8 @@ jobs:
python setup.py bdist_wheel
- uses: actions/upload-artifact@v4
with:
path: ./dist/*.whl
name: artifact-wheel
path: ./dist/*.whl


build_sdist:
Expand All @@ -63,6 +65,7 @@ jobs:

- uses: actions/upload-artifact@v4
with:
name: artifact-sdist
path: dist/*.tar.gz

upload_pypi:
Expand All @@ -72,12 +75,17 @@ jobs:
steps:
- uses: actions/download-artifact@v4
with:
name: artifact
name: artifact-sdist
path: dist

- uses: actions/download-artifact@v4
with:
name: artifact-wheel
path: dist

- uses: pypa/gh-action-pypi-publish@master
with:
user: __token__
password: ${{ secrets.upload_pypi }}
#password: ${{ secrets.test_pypi }}
#repository_url: https://test.pypi.org/legacy/
# user: __token__
# password: ${{ secrets.upload_pypi }}
password: ${{ secrets.test_pypi }}
repository_url: https://test.pypi.org/legacy/

0 comments on commit df3dd63

Please sign in to comment.