Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add Haskell-Language-Server as a build input to the shell environment.
Adds the Haskell-Language-Server currently at version 1.1.0 (not yet released in Hackage) through a niv dependency. For a final user, adding this is fine because it is cached by Hydra so it will just download the whole shell. Incidentally: Using the same set of nixpkgs as for the rest of the build when providing it to Niv for non-builtin fetchers. Replaced the sources.nix file with a newer generated version (probably this should actually be updated each time we update the niv version). Also rephrase how stylish-haskell was being built as we can just point to the repository at a specific branch with niv. Adding .envrc to .gitignore as not everybody uses lorri. Co-authored-by: Pawel Szulc paul.szulc@gmail.com
- Loading branch information
Showing
7 changed files
with
91 additions
and
37 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,22 @@ | ||
{ pkgs | ||
, ghcVersion | ||
}: | ||
let | ||
inherit (pkgs.commonLib) sources; | ||
|
||
planConfig = { | ||
compiler-nix-name = ghcVersion; | ||
# get the sources from niv | ||
src = sources.hls-released; | ||
configureArgs = "--disable-benchmarks"; | ||
modules = [{ enableSeparateDataOutput = true; }]; | ||
}; | ||
|
||
# bring all exes into scope | ||
hlsExes = (pkgs.haskell-nix.cabalProject planConfig).haskell-language-server.components.exes; | ||
in | ||
{ | ||
hls = hlsExes.haskell-language-server; | ||
hls-wrapper = hlsExes.haskell-language-server-wrapper; | ||
implicit-hie = pkgs.haskellPackages.implicit-hie; | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,17 +1,15 @@ | ||
{ pkgs | ||
, ghcVersion | ||
}: | ||
let | ||
hsPkgs = pkgs.haskell-nix.stackProject { | ||
compiler-nix-name = "ghc8104"; | ||
inherit (pkgs.commonLib) sources; | ||
|
||
planConfig = { | ||
compiler-nix-name = ghcVersion; | ||
# get the sources from niv | ||
src = sources.stylish-haskell; | ||
modules = [ ]; | ||
src = pkgs.fetchFromGitHub { | ||
owner = "jaspervdj"; | ||
repo = "stylish-haskell"; | ||
# 0.12.2.0 with custom feature that will be added to 0.12.3.0 release | ||
# see https://github.com/jaspervdj/stylish-haskell/commit/3d5348041e2efbcae95f1c62ace5ac0ffd9629d2 | ||
rev = "3d5348041e2efbcae95f1c62ace5ac0ffd9629d2"; | ||
sha256 = "1rms68fll6w1rzdg9ppjs9g246mbgxi5589vxb8r8pcn5v1ncfj2"; | ||
}; | ||
}; | ||
|
||
in | ||
hsPkgs.stylish-haskell.components.exes.stylish-haskell | ||
(pkgs.haskell-nix.stackProject planConfig).stylish-haskell.components.exes.stylish-haskell |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters