mirror of
https://github.com/actions/python-versions.git
synced 2026-05-29 00:16:10 +08:00
Replace deprecated create-release action with GitHub CLI (#383)
This commit is contained in:
20
.github/workflows/build-python-packages.yml
vendored
20
.github/workflows/build-python-packages.yml
vendored
@@ -199,14 +199,18 @@ jobs:
|
||||
|
||||
- name: Publish Release ${{ env.VERSION }}
|
||||
id: create_release
|
||||
uses: actions/create-release@v1
|
||||
env:
|
||||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
||||
with:
|
||||
tag_name: ${{ env.VERSION }}-${{ github.run_id }}
|
||||
release_name: ${{ env.VERSION }}
|
||||
body: |
|
||||
Python ${{ env.VERSION }}
|
||||
env:
|
||||
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
||||
shell: bash
|
||||
run: |
|
||||
tag_name="${{ env.VERSION }}-${{ github.run_id }}"
|
||||
gh release create "$tag_name" \
|
||||
--repo="$GITHUB_REPOSITORY" \
|
||||
--title="${{ env.VERSION }}" \
|
||||
--notes="Python ${{ env.VERSION }}"
|
||||
|
||||
release_id=$(gh release view "$tag_name" --repo "$GITHUB_REPOSITORY" --json databaseId --jq '.databaseId')
|
||||
echo "id=$release_id" >> $GITHUB_OUTPUT
|
||||
|
||||
- name: Generate hash for packages
|
||||
run: |
|
||||
|
||||
Reference in New Issue
Block a user