2021-07-13 13:42:20 +00:00
|
|
|
name: Create Release
|
|
|
|
|
|
|
|
on:
|
|
|
|
push:
|
|
|
|
tags:
|
|
|
|
- 'v*'
|
|
|
|
|
|
|
|
jobs:
|
2022-10-20 12:37:50 +00:00
|
|
|
release-linux:
|
|
|
|
name: Create Release x86_64
|
2021-07-13 13:42:20 +00:00
|
|
|
runs-on: ${{ matrix.os }}
|
|
|
|
env:
|
2022-10-20 12:37:50 +00:00
|
|
|
CABAL_VER: 3.6.2.0
|
|
|
|
CACHE_VER: 1
|
2021-07-13 13:42:20 +00:00
|
|
|
MACOSX_DEPLOYMENT_TARGET: 10.13
|
|
|
|
strategy:
|
|
|
|
matrix:
|
2022-10-20 12:37:50 +00:00
|
|
|
include:
|
|
|
|
- os: ubuntu-latest
|
|
|
|
ARTIFACT: "i386-linux-ghcup"
|
|
|
|
GHC_VER: 8.10.7
|
|
|
|
ARCH: 32
|
|
|
|
- os: ubuntu-latest
|
|
|
|
ARTIFACT: "x86_64-linux-ghcup"
|
|
|
|
GHC_VER: 8.10.7
|
|
|
|
ARCH: 64
|
|
|
|
- os: [self-hosted, macOS, aarch64]
|
|
|
|
ARTIFACT: "aarch64-apple-darwin-ghcup"
|
|
|
|
GHC_VER: 9.2.5
|
|
|
|
ARCH: 64
|
|
|
|
- os: macOS-10.15
|
|
|
|
ARTIFACT: "x86_64-apple-darwin-ghcup"
|
|
|
|
GHC_VER: 9.2.5
|
|
|
|
ARCH: 64
|
|
|
|
- os: windows-latest
|
|
|
|
ARTIFACT: "x86_64-mingw64-ghcup"
|
|
|
|
GHC_VER: 8.10.7
|
|
|
|
ARCH: 64
|
2021-07-13 13:42:20 +00:00
|
|
|
steps:
|
|
|
|
- name: Checkout code
|
2022-10-20 12:37:50 +00:00
|
|
|
uses: actions/checkout@v3
|
2021-07-13 13:42:20 +00:00
|
|
|
|
2022-10-20 12:37:50 +00:00
|
|
|
- if: matrix.ARCH == '32' && runner.os == 'Linux'
|
|
|
|
name: Run release (32 bit linux)
|
|
|
|
uses: docker://i386/alpine:3.12
|
2021-07-13 13:42:20 +00:00
|
|
|
with:
|
2022-10-20 12:37:50 +00:00
|
|
|
args: sh .github/scripts/release.sh
|
|
|
|
env:
|
|
|
|
ARTIFACT: ${{ matrix.ARTIFACT }}
|
|
|
|
ARCH: ${{ matrix.ARCH }}
|
|
|
|
GHC_VER: ${{ matrix.GHC_VER }}
|
2021-07-13 13:42:20 +00:00
|
|
|
|
2022-10-20 12:37:50 +00:00
|
|
|
- if: matrix.ARCH == '64' && runner.os == 'Linux'
|
|
|
|
name: Run release (64 bit linux)
|
|
|
|
uses: docker://alpine:3.12
|
|
|
|
with:
|
|
|
|
args: sh .github/scripts/release.sh
|
|
|
|
env:
|
|
|
|
ARTIFACT: ${{ matrix.ARTIFACT }}
|
|
|
|
ARCH: ${{ matrix.ARCH }}
|
|
|
|
GHC_VER: ${{ matrix.GHC_VER }}
|
2021-07-13 13:42:20 +00:00
|
|
|
|
2022-10-20 12:37:50 +00:00
|
|
|
- if: runner.os != 'Linux'
|
|
|
|
name: Run release (windows/mac)
|
|
|
|
run: bash .github/scripts/release.sh
|
2021-07-13 13:42:20 +00:00
|
|
|
env:
|
2022-10-20 12:37:50 +00:00
|
|
|
ARTIFACT: ${{ matrix.ARTIFACT }}
|
|
|
|
ARCH: ${{ matrix.ARCH }}
|
|
|
|
GHC_VER: ${{ matrix.GHC_VER }}
|
2021-07-13 13:42:20 +00:00
|
|
|
|
|
|
|
- if: always()
|
2022-10-20 12:37:50 +00:00
|
|
|
uses: actions/upload-artifact@v3
|
2021-07-13 13:42:20 +00:00
|
|
|
with:
|
2022-10-20 12:37:50 +00:00
|
|
|
name: artifacts
|
|
|
|
path: |
|
|
|
|
./out/*
|
|
|
|
./dist-newstyle/cache/plan.json
|
2021-07-13 13:42:20 +00:00
|
|
|
|
2022-10-20 12:37:50 +00:00
|
|
|
- name: Release
|
|
|
|
uses: softprops/action-gh-release@v1
|
|
|
|
with:
|
|
|
|
draft: true
|
|
|
|
files: |
|
|
|
|
./out/*
|
|
|
|
./dist-newstyle/cache/plan.json
|