Skip to content

Commit

Permalink
Replace deprecated set-output in workflows
Browse files Browse the repository at this point in the history
  • Loading branch information
Mark R. Tuttle authored and markrtuttle committed Dec 21, 2022
1 parent 6e5acf4 commit 12afea9
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 10 deletions.
10 changes: 4 additions & 6 deletions .github/workflows/release-brew.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -107,15 +107,13 @@ jobs:
- name: Get Package Path
id: get_package_path
run: |
bottle_name="$(ls *.tar.gz)"
echo "::set-output name=bottle::$bottle_name"
echo "bottle=$(ls *.tar.gz)" >> $GITHUB_ENV
- name: Get File Name
id: get_file_name
run: |
brew install jq
file_name="$(cat *.json | jq -r '."${{ env.TAP }}/${{ env.FORMULA }}".bottle.tags[].filename')"
echo "::set-output name=file_name::$file_name"
echo "file_name=$(jq -r '."${{ env.TAP }}/${{ env.FORMULA }}".bottle.tags[].filename' *.json)" >> $GITHUB_ENV
- name: Upload bottles as artifact
uses: actions/upload-artifact@main
Expand All @@ -129,8 +127,8 @@ jobs:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
upload_url: ${{ github.event.release.upload_url }}
asset_path: ${{ steps.get_package_path.outputs.bottle }}
asset_name: ${{ steps.get_file_name.outputs.file_name }}
asset_path: ${{ env.bottle }}
asset_name: ${{ env.file_name }}
asset_content_type: application/x-gzip

update-pr:
Expand Down
7 changes: 3 additions & 4 deletions .github/workflows/release-pypi.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -16,16 +16,15 @@ jobs:
- name: Get Package Name
id: get_package_name
run: |
package_name="$(ls dist/*.whl | cut -d "/" -f 2)"
echo "::set-output name=package_name::$package_name"
echo "package_name=$(ls dist/*.whl | cut -d "/" -f 2)" >> $GITHUB_ENV
- name: Upload release binary
uses: actions/[email protected]
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
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_path: dist/${{ env.package_name }}
asset_name: ${{ env.package_name }}
asset_content_type: application/zip
- name: Upload to PyPi
env:
Expand Down

0 comments on commit 12afea9

Please sign in to comment.