Skip to content

Commit 427fcf3

Browse files
committed
Make HLS work in gitpod
1 parent 415602f commit 427fcf3

File tree

1 file changed

+11
-1
lines changed

1 file changed

+11
-1
lines changed

.gitpod.yml

Lines changed: 11 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,17 @@ tasks:
66
export CABAL_DIR=/workspace/.cabal
77
export STACK_ROOT=/workspace/.stack
88
curl --proto '=https' --tlsv1.2 -sSf https://get-ghcup.haskell.org | sh
9-
source /workspace/.ghcup/env
9+
10+
# ensure that there is an HLS binary for the installed GHC version
11+
ghcup install --set ghc 8.10.6
12+
13+
# Fix the default Cabal config since VSCode does not see CABAL_DIR
14+
mkdir ~/.cabal
15+
cp /workspace/.cabal/config ~/.cabal/config
16+
17+
# Add ghcup binaries to the PATH since VSCode does not see 'source .ghcup/env'
18+
cd /usr/local/bin
19+
sudo ln -s /workspace/.ghcup/bin/* /usr/local/bin
1020
init: |
1121
cabal build --enable-tests
1222
command: |

0 commit comments

Comments
 (0)