Skip to content

Commit

Permalink
Use action-gh-release
Browse files Browse the repository at this point in the history
  • Loading branch information
hatstand committed Oct 14, 2024
1 parent f636992 commit 552e19a
Showing 1 changed file with 15 additions and 6 deletions.
21 changes: 15 additions & 6 deletions .github/workflows/all.yml
Original file line number Diff line number Diff line change
Expand Up @@ -108,24 +108,33 @@ jobs:
# - build_mac
- build_mingw
- build_source
permissions:
contents: write
steps:
- uses: actions/checkout@v1.2.0
- uses: actions/download-artifact@v4
with:
path: release_artifacts
- name: Create draft pre-release
id: tag_name
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
run: |
set -x
VERSION=$(echo release_artifacts/**/*.tar.xz | sed -e 's/.*clementine-\(.*\).tar.xz/\1/')
echo "Version: ${VERSION}"
assets=()
for asset in $(find release_artifacts -type f); do
echo "Adding asset: ${asset}"
assets+=("-a" "$asset")
done
hub release create -p "${assets[@]}" -m "$VERSION" -t "$GITHUB_SHA" "$VERSION"
echo "version=${VERSION}" >> "$GITHUB_OUTPUT"
- name: Create draft pre-release
uses: softprops/action-gh-release@v2
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
name: ${{ steps.tag_name.outputs.version }}
tag_name: ${{ steps.tag_name.outputs.version }}
files: "release_artifacts/**/*"
fail_on_unmatched_files: true
draft: true
prerelease: true

build_source:
name: Build source tarball
Expand Down

0 comments on commit 552e19a

Please sign in to comment.