Skip to content

Commit

Permalink
Upgrade HLS to 1.9.0
Browse files Browse the repository at this point in the history
  • Loading branch information
zeme-wana committed Jan 31, 2023
1 parent f21116d commit a0ba5a1
Show file tree
Hide file tree
Showing 6 changed files with 26 additions and 44 deletions.
@@ -1,4 +1,4 @@
# TODO(std) DUP(except the constratins and the actual version)
# TODO(std) DUP

{ inputs, cell }:

Expand All @@ -14,13 +14,11 @@ cell.library.pkgs.haskell-nix.cabalProject' {
# tools which HLS uses explicitly
# b) Pull out the tools themselves from the HLS project so we can use
# them elsewhere

# cabalProjectLocal = ''
# constraints: stylish-haskell==0.14.2.0, hlint==3.4.1
# '';

src = inputs.haskell-language-server;

sha256map = {
"https://github.com/pepeiborra/ekg-json"."7a0af7a8fd38045fd15fb13445bdcc7085325460" = "sha256-fVwKxGgM0S4Kv/4egVAAiAjV7QB5PBqMVMCfsv7otIQ="; # editorconfig-checker-disable-line
};
Expand Down
25 changes: 4 additions & 21 deletions __std__/flake.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion __std__/flake.nix
Expand Up @@ -45,7 +45,7 @@
flake = false;
};
haskell-language-server = {
url = "github:haskell/haskell-language-server?ref=1.5.1";
url = "github:haskell/haskell-language-server?ref=1.9.0.0";
flake = false;
};
plutus-core = {
Expand Down
8 changes: 4 additions & 4 deletions flake.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

3 changes: 1 addition & 2 deletions flake.nix
Expand Up @@ -37,8 +37,7 @@
flake = false;
};
haskell-language-server = {
# Pinned to a release
url = "github:haskell/haskell-language-server?ref=1.5.1";
url = "github:haskell/haskell-language-server?ref=1.9.0.0";
flake = false;
};
iohk-nix = {
Expand Down
28 changes: 15 additions & 13 deletions nix/pkgs/haskell/extra.nix
Expand Up @@ -42,24 +42,26 @@ let
};
hlsProject = haskell-nix.cabalProject' {
# See https://github.com/haskell/haskell-language-server/issues/411.
# We want to use stylish-haskell, hlint, and implicit-hie as standalone tools *and* through HLS. But we need to have consistent versions in both
# cases, otherwise e.g. you could format the code in HLS and then have the CI complain that it's wrong.
# We want to use stylish-haskell, hlint, and implicit-hie as standalone tools
# *and* through HLS. But we need to have consistent versions in both cases,
# otherwise e.g. you could format the code in HLS and then have the CI
# complain that it's wrong
#
# The solution we use here is to:
# a) Where we care (mostly just formatters), constrain the versions of tools which HLS uses explicitly
# b) pull out the tools themselves from the HLS project so we can use them elsewhere
cabalProjectLocal = ''
constraints: stylish-haskell==0.13.0.0, hlint==3.2.7
allow-newer: hls-stylish-haskell-plugin:stylish-haskell
'';
# a) Where we care (mostly just formatters), constrain the versions of
# tools which HLS uses explicitly
# b) Pull out the tools themselves from the HLS project so we can use
# them elsewhere


src = sources.haskell-language-server;
inherit compiler-nix-name;
sha256map = {
"https://github.com/hsyl20/ghc-api-compat"."8fee87eac97a538dbe81ff1ab18cff10f2f9fa15" = "16bibb7f3s2sxdvdy2mq6w1nj1lc8zhms54lwmj17ijhvjys29vg";
"https://github.com/haskell/lsp.git"."ef59c28b41ed4c5775f0ab0c1e985839359cec96" = "1whcgw4hhn2aplrpy9w8q6rafwy7znnp0rczgr6py15fqyw2fwb5";
"https://github.com/pepeiborra/ekg-json"."7a0af7a8fd38045fd15fb13445bdcc7085325460" = "sha256-fVwKxGgM0S4Kv/4egVAAiAjV7QB5PBqMVMCfsv7otIQ="; # editorconfig-checker-disable-line
};

inherit compiler-nix-name;

modules = [{
# Workaround for https://github.com/haskell/haskell-language-server/issues/1160
packages.haskell-language-server.patches = lib.mkIf stdenv.isDarwin [ ../../patches/haskell-language-server-dynamic.patch ];
# See https://github.com/haskell/haskell-language-server/pull/1382#issuecomment-780472005
packages.ghcide.flags.ghc-patched-unboxed-bytecode = true;
}];
Expand Down

0 comments on commit a0ba5a1

Please sign in to comment.