From e0ae80385f950a4fc241c827dd194b2d341de7d4 Mon Sep 17 00:00:00 2001 From: fendor Date: Wed, 7 Aug 2024 14:21:49 +0200 Subject: [PATCH] Manually install ghcup into image (#1119) * Manually install ghcup into image * WIP --- .github/workflows/test.yml | 26 +++++++++++++++++++++----- 1 file changed, 21 insertions(+), 5 deletions(-) diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index 46f0950a..e8edf075 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -11,7 +11,7 @@ jobs: strategy: fail-fast: false matrix: - os: [macos-12, ubuntu-latest, windows-latest] + os: [macos-latest, ubuntu-latest, windows-latest] ghc: [8.10.7, 9.4.8, 9.6.4, 9.8.2] runs-on: ${{ matrix.os }} steps: @@ -29,10 +29,26 @@ jobs: - run: yarn run webpack # Setup toolchains, install ghcup, install ghc, etc... - - name: Setup Haskell - uses: haskell-actions/setup@v2 - with: - ghc-version: ${{ matrix.ghc }} + - name: Install GHCup + run: | + curl --proto '=https' --tlsv1.2 -sSf https://get-ghcup.haskell.org | sh + shell: bash + env: + BOOTSTRAP_HASKELL_NONINTERACTIVE: 1 + BOOTSTRAP_HASKELL_MINIMAL: 1 + + - name: Check GHCup (Windows) + run: | + echo "c:/ghcup/bin" >> $GITHUB_PATH + shell: bash + if: runner.os == 'Windows' + + - name: Check GHCup (Unix) + run: | + echo "${HOME}/.ghcup/bin" >> $GITHUB_PATH + shell: bash + if: runner.os != 'Windows' + - name: Toolchain settings run: | ghcup upgrade -i -f