Skip to content

Commit 40a6f50

Browse files
authored
Fix publishing a GitHub Release from GHA (#811)
1 parent e5e900f commit 40a6f50

File tree

1 file changed

+20
-7
lines changed

1 file changed

+20
-7
lines changed

.github/workflows/test-library.yml

Lines changed: 20 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -802,6 +802,7 @@ jobs:
802802

803803
permissions:
804804
contents: write
805+
discussions: write
805806

806807
steps:
807808
- name: Download all the dists
@@ -813,15 +814,27 @@ jobs:
813814
- name: >-
814815
Publish a GitHub Release for
815816
${{ needs.pre-setup.outputs.git-tag }}
816-
uses: softprops/action-gh-release@v1
817+
uses: ncipollo/release-action@v1.8.10
817818
with:
818-
# body/body_path: # FIXME: Use once Towncrier is integrated.
819-
discussion_category_name: Announcements
820-
fail_on_unmatched_files: true
821-
files: |
819+
allowUpdates: false
820+
artifactErrorsFailBuild: false
821+
artifacts: |
822822
dist/${{ needs.pre-setup.outputs.sdist-artifact-name }}
823823
dist/${{ needs.pre-setup.outputs.wheel-artifact-name }}
824+
artifactContentType: raw # Because whl and tgz are of different types
825+
# body/bodyFile: # FIXME: Use once Towncrier is integrated.
826+
commit: ${{ github.event.inputs.release-commitish }}
827+
discussionCategory: Announcements
828+
draft: false
824829
name: ${{ needs.pre-setup.outputs.git-tag }}
825-
tag_name: ${{ needs.pre-setup.outputs.git-tag }}
826-
target_commitish: ${{ github.event.inputs.release-commitish }}
830+
# omitBody: false
831+
omitBodyDuringUpdate: true
832+
omitName: false
833+
omitNameDuringUpdate: true
834+
omitPrereleaseDuringUpdate: true
835+
prerelease: false
836+
removeArtifacts: false
837+
replacesArtifacts: false
838+
tag: ${{ needs.pre-setup.outputs.git-tag }}
839+
token: ${{ secrets.GITHUB_TOKEN }}
827840
...

0 commit comments

Comments
 (0)