Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Use action-gh-release to replace deprecated upload-release-asset #174

Merged
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
13 changes: 2 additions & 11 deletions .github/workflows/release-brew.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -136,25 +136,16 @@ jobs:
run: |
echo "bottle_name=$(ls *.tar.gz)" >> $GITHUB_OUTPUT

- name: Get File Name
id: get_file_name
run: |
file_name="$(cat *.json | jq -r '."${{ env.TAP }}/${{ env.FORMULA }}".bottle.tags[].filename')"
echo "file_name=$file_name" >> $GITHUB_OUTPUT

- name: Upload bottles as artifact
uses: actions/upload-artifact@v4
with:
name: bottle-${{ matrix.os }}
path: '*.bottle.*'

- name: Upload release binary
uses: actions/[email protected]
uses: softprops/action-gh-release@v2
with:
upload_url: ${{ github.event.release.upload_url }}
asset_path: ${{ steps.get_package_path.outputs.bottle_name }}
asset_name: ${{ steps.get_file_name.outputs.file_name }}
asset_content_type: application/x-gzip
files: ${{ steps.get_package_path.outputs.bottle_name }}

update-pr:
needs: build-bottle
Expand Down
7 changes: 2 additions & 5 deletions .github/workflows/release-pypi.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -38,12 +38,9 @@ jobs:
run: |
echo "package_name=$(ls dist/*.whl | cut -d / -f 2)" >> $GITHUB_OUTPUT
- name: Upload release binary
uses: actions/[email protected]
uses: softprops/action-gh-release@v2
with:
upload_url: ${{ github.event.release.upload_url }}
asset_path: dist/${{ steps.get_package_name.outputs.package_name }}
asset_name: ${{ steps.get_package_name.outputs.package_name }}
asset_content_type: application/zip
files: dist/${{ steps.get_package_name.outputs.package_name }}
- name: Upload to PyPi
env:
TWINE_USERNAME: __token__
Expand Down
Loading