Skip to content

Commit 85b51c4

Browse files
CI: cabal 3.6 use & clean-up 8.10.5 builds (#2443)
* CI: (cache-deps->caching) * CI: caching: add doc * CI: rm 8.10.5 Since next HLS release is no longer supports this version. * CI: update to currently recommended Cabal version Co-authored-by: Javier Neira <[email protected]>
1 parent bdb946b commit 85b51c4

File tree

5 files changed

+24
-31
lines changed

5 files changed

+24
-31
lines changed

.github/workflows/bench.yml

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -32,6 +32,7 @@ jobs:
3232
matrix:
3333
ghc: ['8.10.7']
3434
os: [ubuntu-latest]
35+
cabal: ['3.6']
3536

3637
steps:
3738
- uses: actions/checkout@v2
@@ -40,8 +41,8 @@ jobs:
4041

4142
- uses: haskell/actions/setup@v1
4243
with:
43-
ghc-version: ${{ matrix.ghc }}
44-
cabal-version: '3.2'
44+
ghc-version : ${{ matrix.ghc }}
45+
cabal-version: ${{ matrix.cabal }}
4546
enable-stack: false
4647

4748
- name: Cache Cabal
@@ -109,8 +110,8 @@ jobs:
109110
steps:
110111
- uses: haskell/actions/setup@v1
111112
with:
112-
ghc-version: ${{ matrix.ghc }}
113-
cabal-version: '3.2'
113+
ghc-version : ${{ matrix.ghc }}
114+
cabal-version: ${{ matrix.cabal }}
114115
enable-stack: false
115116

116117
- name: Download cabal home

.github/workflows/build.yml

Lines changed: 4 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -18,8 +18,9 @@ jobs:
1818
strategy:
1919
fail-fast: false
2020
matrix:
21-
ghc: ['9.0.1', '8.10.7', '8.10.6', '8.10.5', '8.8.4', '8.8.3', '8.6.5']
21+
ghc: ['9.0.1', '8.10.7', '8.10.6', '8.8.4', '8.8.3', '8.6.5']
2222
os: [ubuntu-18.04, macOS-latest, windows-latest]
23+
cabal: ['3.6']
2324
exclude:
2425
- os: windows-latest
2526
ghc: '8.8.3' # fails due to segfault
@@ -30,8 +31,8 @@ jobs:
3031
submodules: true
3132
- uses: haskell/actions/setup@v1
3233
with:
33-
ghc-version: ${{ matrix.ghc }}
34-
cabal-version: '3.4'
34+
ghc-version : ${{ matrix.ghc }}
35+
cabal-version: ${{ matrix.cabal }}
3536

3637
- name: Use modified cabal.project for ghc9
3738
if: ${{ matrix.ghc == '9.0.1' }}
@@ -68,12 +69,6 @@ jobs:
6869
run: |
6970
echo "GHC_VERSION=$GHC_VER" >> $GITHUB_ENV
7071
71-
- name: Workaround for GHC 8.10.5 on macOS
72-
if: matrix.os == 'macOS-latest' && matrix.ghc == '8.10.5'
73-
run: |
74-
echo "# uninstalling CommandLineTools (see https://github.com/haskell/haskell-language-server/issues/1913#issuecomment-861667786)"
75-
sudo rm -rf /Library/Developer/CommandLineTools
76-
7772
- name: Modify cabal.project to workaround segfaults for ghc-8.8.4 and windows
7873
if: matrix.ghc == '8.8.4' && matrix.os == 'windows-latest'
7974
run: |

.github/workflows/cache-deps.yml renamed to .github/workflows/caching.yml

Lines changed: 8 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,8 @@
1-
name: Caching of dependencies
1+
name: Caching
22

3-
# 2021-11-30: NOTE: This workflow currently a trimmed copy of a main `test.yml` workflow. Workflows need further deduplication: https://docs.github.com/en/actions/learn-github-actions/reusing-workflows#overview
3+
# Docs on the workflow:
4+
# 1. GitHub cache scoping goes: main branch -> PR main branch -> PR. (essentially in a tree fashion). That is why it is useful to build caches on `master` - to generate & keep the main project state & they would be shared to the whole tree.
5+
# 2. GitHub has a 10G default limit of cache pool per repo. HLS is a big project & monorepo of many projects, so to keep cache useful - the main branch state caches should be preserved & their storage preferred to the PRs, since PRs from internal branches - would count into 10G pool, but would be available only inside of the PR scope, which can bork cache fore the whole community. That is short story why `dist-newstyle` (especially full) - is not includded into `master` cache.
46

57
defaults:
68
run:
@@ -44,8 +46,9 @@ jobs:
4446
runs-on: ${{ matrix.os }}
4547
strategy:
4648
matrix:
47-
ghc: ["9.0.1", '8.10.7', '8.10.6', "8.10.5", "8.8.4", "8.8.3", "8.6.5"]
49+
ghc: ["9.0.1", '8.10.7', '8.10.6', "8.8.4", "8.8.3", "8.6.5"]
4850
os: [ubuntu-latest, macOS-latest, windows-latest]
51+
cabal: ['3.6']
4952
exclude:
5053
- os: windows-latest
5154
ghc: '8.8.3'
@@ -56,8 +59,8 @@ jobs:
5659
submodules: true
5760
- uses: haskell/actions/setup@v1
5861
with:
59-
ghc-version: ${{ matrix.ghc }}
60-
cabal-version: "3.4"
62+
ghc-version : ${{ matrix.ghc }}
63+
cabal-version: ${{ matrix.cabal }}
6164

6265
- if: matrix.os == 'windows-latest'
6366
name: Set some window specific things

.github/workflows/hackage.yml

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -33,6 +33,7 @@ jobs:
3333
"8.10.7",
3434
"8.8.4",
3535
"8.6.5"]
36+
cabal: ['3.6']
3637
exclude:
3738
- ghc: "9.0.1"
3839
package: "hls-brittany-plugin"
@@ -51,8 +52,8 @@ jobs:
5152

5253
- uses: haskell/actions/setup@v1
5354
with:
54-
ghc-version: ${{ matrix.ghc }}
55-
cabal-version: '3.4'
55+
ghc-version : ${{ matrix.ghc }}
56+
cabal-version: ${{ matrix.cabal }}
5657

5758
- name: Cache Cabal
5859
uses: actions/cache@v2

.github/workflows/test.yml

Lines changed: 4 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -40,8 +40,9 @@ jobs:
4040
strategy:
4141
fail-fast: true
4242
matrix:
43-
ghc: ["9.0.1", '8.10.7', '8.10.6', "8.10.5", "8.8.4", "8.8.3", "8.6.5"]
43+
ghc: ["9.0.1", '8.10.7', '8.10.6', "8.8.4", "8.8.3", "8.6.5"]
4444
os: [ubuntu-latest, macOS-latest]
45+
cabal: ['3.6']
4546
include:
4647
# only test supported ghc major versions
4748
- os: ubuntu-latest
@@ -68,8 +69,6 @@ jobs:
6869
# only build rest of supported ghc versions for windows
6970
- os: windows-latest
7071
ghc: '8.10.6'
71-
- os: windows-latest
72-
ghc: '8.10.5'
7372
- os: windows-latest
7473
ghc: '8.8.4'
7574

@@ -79,8 +78,8 @@ jobs:
7978
submodules: true
8079
- uses: haskell/actions/setup@v1
8180
with:
82-
ghc-version: ${{ matrix.ghc }}
83-
cabal-version: "3.4"
81+
ghc-version : ${{ matrix.ghc }}
82+
cabal-version: ${{ matrix.cabal }}
8483

8584
- run: ./fmt.sh
8685
name: "HLint via ./fmt.sh"
@@ -97,12 +96,6 @@ jobs:
9796
echo "CABAL_STORE_DIR=~/.cabal/store" >> $GITHUB_ENV
9897
echo "CABAL_PKGS_DIR=~/.cabal/packages" >> $GITHUB_ENV
9998
100-
- if: matrix.os == 'macOS-latest' && matrix.ghc == '8.10.5'
101-
name: Workaround for GHC 8.10.5 on macOS
102-
run: |
103-
echo "# uninstalling CommandLineTools (see https://github.com/haskell/haskell-language-server/issues/1913#issuecomment-861667786)"
104-
sudo rm -rf /Library/Developer/CommandLineTools
105-
10699
# Needs to be before Cache Cabal so the cache can detect changes to the modified cabal.project file
107100
- if: matrix.ghc == '9.0.1'
108101
name: Use modified cabal.project for ghc9

0 commit comments

Comments
 (0)