Skip to content

Commit

Permalink
Update release workflow
Browse files Browse the repository at this point in the history
  • Loading branch information
MaybeJustJames committed Feb 2, 2022
1 parent da34073 commit 3f472d4
Showing 1 changed file with 21 additions and 73 deletions.
94 changes: 21 additions & 73 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -26,17 +26,21 @@ jobs:
steps:
- name: Checkout code
uses: actions/checkout@v2
- uses: actions/[email protected]

- uses: haskell/actions/setup@v1
with:
ghc-version: '8.6.5'
cabal-version: '3.2'
ghc-version: 8.10.7
cabal-version: 3.6.2.0

- name: Build zephyr
run: bash bundle/build.sh ${{ runner.os }}

- name: Upload tar file
uses: actions/upload-artifact@v2
with:
name: ${{ runner.os }}.tar.gz
path: bundle/${{ runner.os }}.tar.gz

- name: Upload sha file
uses: actions/upload-artifact@v2
with:
Expand All @@ -48,17 +52,6 @@ jobs:
name: Create Release
runs-on: ubuntu-latest
steps:
- name: Create Release
id: create_release
uses: actions/create-release@v1
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
tag_name: ${{ github.ref }}
release_name: Release ${{ github.ref }}
draft: true
prerelease: false

- name: Download Linux.tar.gz
uses: actions/download-artifact@v2
with:
Expand All @@ -67,26 +60,6 @@ jobs:
uses: actions/download-artifact@v2
with:
name: Linux.sha
- name: Upload Linux.tar.gz
id: upload-Linux
uses: actions/upload-release-asset@v1
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
upload_url: ${{ steps.create_release.outputs.upload_url }}
asset_path: Linux.tar.gz
asset_name: Linux.tar.gz
asset_content_type: application/zip
- name: Upload Linux.sha
id: upload-Linux-sha
uses: actions/upload-release-asset@v1
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
upload_url: ${{ steps.create_release.outputs.upload_url }}
asset_path: Linux.sha
asset_name: Linux.sha
asset_content_type: application/zip

- name: Download macOS.tar.gz
uses: actions/download-artifact@v2
Expand All @@ -96,26 +69,6 @@ jobs:
uses: actions/download-artifact@v2
with:
name: macOS.sha
- name: Upload macOS.tar.gz
id: upload-macOS
uses: actions/upload-release-asset@v1
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
upload_url: ${{ steps.create_release.outputs.upload_url }}
asset_path: macOS.tar.gz
asset_name: macOS.tar.gz
asset_content_type: application/zip
- name: Upload macOS.sha
id: upload-macOS-sha
uses: actions/upload-release-asset@v1
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
upload_url: ${{ steps.create_release.outputs.upload_url }}
asset_path: macOS.sha
asset_name: macOS.sha
asset_content_type: application/zip

- name: Download Windows.tar.gz
uses: actions/download-artifact@v2
Expand All @@ -125,23 +78,18 @@ jobs:
uses: actions/download-artifact@v2
with:
name: Windows.sha
- name: Upload Windows.tar.gz
id: upload-Windows
uses: actions/upload-release-asset@v1
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
upload_url: ${{ steps.create_release.outputs.upload_url }}
asset_path: Windows.tar.gz
asset_name: Windows.tar.gz
asset_content_type: application/zip
- name: Upload Windows.sha
id: upload-Windows-sha
uses: actions/upload-release-asset@v1
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}

- name: Create release
uses: softprops/action-gh-release@v1
with:
upload_url: ${{ steps.create_release.outputs.upload_url }}
asset_path: Windows.sha
asset_name: Windows.sha
asset_content_type: application/zip
tag_name: ${{ github.ref }}
name: Release ${{ github.ref }}
prerelease: false
draft: true
files: |
Linux.tar.gz
Linux.sha
macOS.tar.gz
macOS.sha
Windows.tar.gz
Windows.sha

0 comments on commit 3f472d4

Please sign in to comment.