Skip to content

Commit e73a821

Browse files
Providence SalumuProvidence Salumu
Providence Salumu
authored and
Providence Salumu
committed
fix default ghc version selection
1 parent cb94942 commit e73a821

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

flake.nix

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -196,14 +196,14 @@
196196
# While HLS still works fine with 8.10 GHCs, we only support the versions that are cached
197197
# by upstream nixpkgs, which now only includes GHC version 9+
198198
supportedGHCs = let
199-
ghcVersion = "ghc" + (pkgs.lib.replaceStrings ["."] [""] pkgs.haskellPackages.ghc.version);
199+
ghcVersion = "ghc" + (builtins.concatStringsSep "" (pkgs.lib.lists.init (builtins.splitVersion pkgs.haskellPackages.ghc.version)));
200200
cases = {
201201
ghc90 = ghc90Config.tweakHpkgs (pkgs.hlsHpkgs "ghc90");
202202
ghc92 = ghc92Config.tweakHpkgs (pkgs.hlsHpkgs "ghc92");
203203
ghc94 = ghc94Config.tweakHpkgs (pkgs.hlsHpkgs "ghc94");
204204
ghc96 = ghc96Config.tweakHpkgs (pkgs.hlsHpkgs "ghc96");
205205
};
206-
in { default = cases."${ghcVersion}"; } // cases;
206+
in { default = cases."${ghcVersion}"; } // cases;
207207

208208
ghc90 = supportedGHCs.ghc90;
209209
ghc92 = supportedGHCs.ghc92;

0 commit comments

Comments
 (0)