From abe59d4c4bdfabc688b9898003844ee20be67613 Mon Sep 17 00:00:00 2001 From: Luke Lau Date: Fri, 2 Oct 2020 19:01:16 +0100 Subject: [PATCH 1/3] Generate .gz tars of all the binaries for macOS and Linux Used by ghcup --- .github/workflows/build.yml | 27 +++++++++++++++++++++++++++ 1 file changed, 27 insertions(+) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index e84d490c68..99b70322a9 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -135,3 +135,30 @@ jobs: name: haskell-language-server-wrapper-${{ runner.OS }}${{env.EXE_EXT}}.${{ steps.compress_wrapper_binary.outputs.extension }} path: ${{ steps.compress_wrapper_binary.outputs.path }} + # this generates .gz tarfiles containing all the GHC versions for + # macOS and Linux, used by ghcup + tar: + needs: build + runs-on: ubuntu-latest + steps: + - uses: actions/download-artifact@v2 + + - run: | + for OS in Linux macOS + do + tar -czf haskell-language-server-$OS-${{ github.event.release.tag_name }}.gz haskell-language-server-$OS-*.gz + done + + - uses: actions/upload-release-asset@v1.0.2 + with: + upload_url: ${{ github.event.release.upload_url }} + asset_path: haskell-language-server-macOS-${{ github.event.release.tag_name }}.gz + asset_name: haskell-language-server-macOS-${{ github.event.release.tag_name }}.gz + asset_content_type: application/gzip + + - uses: actions/upload-release-asset@v1.0.2 + with: + upload_url: ${{ github.event.release.upload_url }} + asset_path: haskell-language-server-Linux-${{ github.event.release.tag_name }}.gz + asset_name: haskell-language-server-Linux-${{ github.event.release.tag_name }}.gz + asset_content_type: application/gzip From e614fd42bc6b46111857700fc1050b9840d3fb9b Mon Sep 17 00:00:00 2001 From: Luke Lau Date: Fri, 2 Oct 2020 19:16:32 +0100 Subject: [PATCH 2/3] Update docs on the release process --- docs/releases.md | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/docs/releases.md b/docs/releases.md index e058ff5855..b6755dd4d8 100644 --- a/docs/releases.md +++ b/docs/releases.md @@ -70,3 +70,15 @@ One caveat is that we need to rename the binaries from haskell-language-server/haskell-language-server-wrapper to hls/hls-wrapper due to path length limitations on windows. But whenever we upload them to the release, we make sure to upload them as their full name variant. + +### ghcup +Ghcup can install hls binaries, provided that there is a tarfile +called `haskell-language-server-{macOS,Linux}-$HLS_VERSION.gz` +included in the GitHub release. The `tar` job in the workflow file automates the creation of this. + +### Windows +Currently building HLS with GHC 8.8.x on Windows is very flakey and so +is not included by default in the GitHub Actions build matrix. Instead +they need to be built and uploaded manually. See [this +PR](https://github.com/haskell/haskell-language-server/issues/276) for +more details From 1e4bfc523c65b1d21ff44902d374ecd5d8e2bf77 Mon Sep 17 00:00:00 2001 From: Luke Lau Date: Fri, 2 Oct 2020 19:17:13 +0100 Subject: [PATCH 3/3] Use actions/setup-haskell v1.1.3 --- .github/workflows/build.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 99b70322a9..2b362dbcbe 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -31,7 +31,7 @@ jobs: - uses: actions/checkout@v2 with: submodules: true - - uses: bubba/setup-haskell@7235984 + - uses: actions/setup-haskell@v1.1.3 with: ghc-version: ${{ matrix.ghc }} cabal-version: '3.2'