Merge pull request #111678 from NixOS/haskell-updates
Update Haskell package set to Stackage Nightly 2021-02-02 (plus other fixes)
This commit is contained in:
commit
e7de728103
|
@ -116,6 +116,16 @@ stdenv.mkDerivation (rec {
|
|||
|
||||
outputs = [ "out" "doc" ];
|
||||
|
||||
patches = [
|
||||
# See upstream patch at
|
||||
# https://gitlab.haskell.org/ghc/ghc/-/merge_requests/4885. Since we build
|
||||
# from source distributions, the auto-generated configure script needs to be
|
||||
# patched as well, therefore we use an in-tree patch instead of pulling the
|
||||
# upstream patch. Don't forget to check backport status of the upstream patch
|
||||
# when adding new GHC releases in nixpkgs.
|
||||
./respect-ar-path.patch
|
||||
];
|
||||
|
||||
postPatch = "patchShebangs .";
|
||||
|
||||
# GHC is a bit confused on its cross terminology.
|
||||
|
|
|
@ -107,8 +107,16 @@ stdenv.mkDerivation (rec {
|
|||
|
||||
outputs = [ "out" "doc" ];
|
||||
|
||||
# https://gitlab.haskell.org/ghc/ghc/-/issues/18549
|
||||
patches = [
|
||||
# See upstream patch at
|
||||
# https://gitlab.haskell.org/ghc/ghc/-/merge_requests/4885. Since we build
|
||||
# from source distributions, the auto-generated configure script needs to be
|
||||
# patched as well, therefore we use an in-tree patch instead of pulling the
|
||||
# upstream patch. Don't forget to check backport status of the upstream patch
|
||||
# when adding new GHC releases in nixpkgs.
|
||||
./respect-ar-path.patch
|
||||
|
||||
# https://gitlab.haskell.org/ghc/ghc/-/issues/18549
|
||||
./issue-18549.patch
|
||||
] ++ lib.optionals stdenv.isDarwin [
|
||||
# Make Block.h compile with c++ compilers. Remove with the next release
|
||||
|
|
|
@ -107,7 +107,15 @@ stdenv.mkDerivation (rec {
|
|||
|
||||
outputs = [ "out" "doc" ];
|
||||
|
||||
patches = lib.optionals stdenv.isDarwin [
|
||||
patches = [
|
||||
# See upstream patch at
|
||||
# https://gitlab.haskell.org/ghc/ghc/-/merge_requests/4885. Since we build
|
||||
# from source distributions, the auto-generated configure script needs to be
|
||||
# patched as well, therefore we use an in-tree patch instead of pulling the
|
||||
# upstream patch. Don't forget to check backport status of the upstream patch
|
||||
# when adding new GHC releases in nixpkgs.
|
||||
./respect-ar-path.patch
|
||||
] ++ lib.optionals stdenv.isDarwin [
|
||||
# Make Block.h compile with c++ compilers. Remove with the next release
|
||||
(fetchpatch {
|
||||
url = "https://gitlab.haskell.org/ghc/ghc/-/commit/97d0b0a367e4c6a52a17c3299439ac7de129da24.patch";
|
||||
|
|
|
@ -110,6 +110,14 @@ stdenv.mkDerivation (rec {
|
|||
outputs = [ "out" "doc" ];
|
||||
|
||||
patches = [
|
||||
# See upstream patch at
|
||||
# https://gitlab.haskell.org/ghc/ghc/-/merge_requests/4885. Since we build
|
||||
# from source distributions, the auto-generated configure script needs to be
|
||||
# patched as well, therefore we use an in-tree patch instead of pulling the
|
||||
# upstream patch. Don't forget to check backport status of the upstream patch
|
||||
# when adding new GHC releases in nixpkgs.
|
||||
./respect-ar-path.patch
|
||||
|
||||
(fetchpatch { # https://phabricator.haskell.org/D5123
|
||||
url = "https://gitlab.haskell.org/ghc/ghc/-/commit/13ff0b7ced097286e0d7b054f050871effe07f86.diff";
|
||||
name = "D5123.diff";
|
||||
|
|
|
@ -111,6 +111,16 @@ stdenv.mkDerivation (rec {
|
|||
|
||||
outputs = [ "out" "doc" ];
|
||||
|
||||
patches = [
|
||||
# See upstream patch at
|
||||
# https://gitlab.haskell.org/ghc/ghc/-/merge_requests/4885. Since we build
|
||||
# from source distributions, the auto-generated configure script needs to be
|
||||
# patched as well, therefore we use an in-tree patch instead of pulling the
|
||||
# upstream patch. Don't forget to check backport status of the upstream patch
|
||||
# when adding new GHC releases in nixpkgs.
|
||||
./respect-ar-path.patch
|
||||
];
|
||||
|
||||
postPatch = "patchShebangs .";
|
||||
|
||||
# GHC is a bit confused on its cross terminology.
|
||||
|
|
|
@ -116,6 +116,16 @@ stdenv.mkDerivation (rec {
|
|||
|
||||
outputs = [ "out" "doc" ];
|
||||
|
||||
patches = [
|
||||
# See upstream patch at
|
||||
# https://gitlab.haskell.org/ghc/ghc/-/merge_requests/4885. Since we build
|
||||
# from source distributions, the auto-generated configure script needs to be
|
||||
# patched as well, therefore we use an in-tree patch instead of pulling the
|
||||
# upstream patch. Don't forget to check backport status of the upstream patch
|
||||
# when adding new GHC releases in nixpkgs.
|
||||
./respect-ar-path.patch
|
||||
];
|
||||
|
||||
postPatch = "patchShebangs .";
|
||||
|
||||
# GHC is a bit confused on its cross terminology.
|
||||
|
|
|
@ -116,6 +116,16 @@ stdenv.mkDerivation (rec {
|
|||
|
||||
outputs = [ "out" "doc" ];
|
||||
|
||||
patches = [
|
||||
# See upstream patch at
|
||||
# https://gitlab.haskell.org/ghc/ghc/-/merge_requests/4885. Since we build
|
||||
# from source distributions, the auto-generated configure script needs to be
|
||||
# patched as well, therefore we use an in-tree patch instead of pulling the
|
||||
# upstream patch. Don't forget to check backport status of the upstream patch
|
||||
# when adding new GHC releases in nixpkgs.
|
||||
./respect-ar-path.patch
|
||||
];
|
||||
|
||||
postPatch = "patchShebangs .";
|
||||
|
||||
# GHC is a bit confused on its cross terminology.
|
||||
|
|
|
@ -96,12 +96,12 @@ let
|
|||
|
||||
in
|
||||
stdenv.mkDerivation (rec {
|
||||
version = "9.0.0.20201227";
|
||||
version = "9.0.1";
|
||||
name = "${targetPrefix}ghc-${version}";
|
||||
|
||||
src = fetchurl {
|
||||
url = "https://downloads.haskell.org/ghc/9.0.1-rc1/ghc-${version}-src.tar.xz";
|
||||
sha256 = "1kg227fzg9qq2p7r8xqr99vvnx7ind4clxkydikyzf3vqvaacjfy";
|
||||
url = "https://downloads.haskell.org/ghc/${version}/ghc-${version}-src.tar.xz";
|
||||
sha256 = "1y9mi9bq76z04hmggavrn8jwi1gx92bm3zhx6z69ypq6wha068x5";
|
||||
};
|
||||
|
||||
enableParallelBuilding = true;
|
||||
|
|
|
@ -0,0 +1,25 @@
|
|||
diff -urd a/aclocal.m4 b/aclocal.m4
|
||||
--- a/aclocal.m4
|
||||
+++ b/aclocal.m4
|
||||
@@ -1199,7 +1199,8 @@
|
||||
# thinks that target == host so it never checks the unqualified
|
||||
# tools for Windows. See #14274.
|
||||
AC_DEFUN([FP_PROG_AR],
|
||||
-[if test -z "$fp_prog_ar"; then
|
||||
+[AC_SUBST(fp_prog_ar,$AR)
|
||||
+if test -z "$fp_prog_ar"; then
|
||||
if test "$HostOS" = "mingw32"
|
||||
then
|
||||
AC_PATH_PROG([fp_prog_ar], [ar])
|
||||
diff -urd a/configure b/configure
|
||||
--- a/configure
|
||||
+++ b/configure
|
||||
@@ -10744,6 +10744,8 @@
|
||||
test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
|
||||
|
||||
|
||||
+fp_prog_ar=$AR
|
||||
+
|
||||
if test -z "$fp_prog_ar"; then
|
||||
if test "$HostOS" = "mingw32"
|
||||
then
|
|
@ -1405,28 +1405,20 @@ self: super: {
|
|||
# quickcheck-instances is only used in the tests of binary-instances.
|
||||
binary-instances = dontCheck super.binary-instances;
|
||||
|
||||
# tons of overrides for bleeding edge versions for ghcide and hls
|
||||
# overriding aeson on all of them to prevent double compilations
|
||||
# this shouldn‘t break anything because nearly all their reverse deps are
|
||||
# in this list or marked as broken anyways
|
||||
# 2020-11-19: Checks nearly fixed, but still disabled because of flaky tests:
|
||||
# https://github.com/haskell/haskell-language-server/issues/610
|
||||
# https://github.com/haskell/haskell-language-server/issues/611
|
||||
haskell-language-server = dontCheck (super.haskell-language-server.override {
|
||||
lsp-test = dontCheck self.lsp-test;
|
||||
fourmolu = self.fourmolu_0_3_0_0;
|
||||
});
|
||||
haskell-language-server = dontCheck super.haskell-language-server;
|
||||
|
||||
# 2021-01-20
|
||||
# apply-refact 0.9.0.0 get's a build error with hls-hlint-plugin 0.8.0
|
||||
# https://github.com/haskell/haskell-language-server/issues/1240
|
||||
apply-refact = super.apply-refact_0_8_2_1;
|
||||
|
||||
fourmolu = dontCheck super.fourmolu;
|
||||
|
||||
# 1. test requires internet
|
||||
# 2. dependency shake-bench hasn't been published yet so we also need unmarkBroken and doDistribute
|
||||
ghcide = doDistribute (unmarkBroken (dontCheck (super.ghcide_0_7_0_0.override { lsp-test = dontCheck self.lsp-test; })));
|
||||
refinery = doDistribute super.refinery_0_3_0_0;
|
||||
ghcide = doDistribute (unmarkBroken (dontCheck super.ghcide));
|
||||
|
||||
data-tree-print = doJailbreak super.data-tree-print;
|
||||
|
||||
# 2020-11-15: aeson 1.5.4.1 needs to new quickcheck-instances for testing
|
||||
|
@ -1527,7 +1519,7 @@ self: super: {
|
|||
|
||||
# 2020-12-05: http-client is fixed on too old version
|
||||
essence-of-live-coding-warp = super.essence-of-live-coding-warp.override {
|
||||
http-client = self.http-client_0_7_4;
|
||||
http-client = self.http-client_0_7_5;
|
||||
};
|
||||
|
||||
# 2020-12-06: Restrictive upper bounds w.r.t. pandoc-types (https://github.com/owickstrom/pandoc-include-code/issues/27)
|
||||
|
|
|
@ -88,5 +88,6 @@ self: super: {
|
|||
|
||||
# ghc versions prior to 8.8.x needs additional dependency to compile successfully.
|
||||
ghc-lib-parser-ex = addBuildDepend super.ghc-lib-parser-ex self.ghc-lib-parser;
|
||||
hls-hlint-plugin = addBuildDepend super.hls-hlint-plugin self.ghc-lib;
|
||||
|
||||
}
|
||||
|
|
|
@ -94,4 +94,9 @@ self: super: {
|
|||
|
||||
# This became a core library in ghc 8.10., so we don‘t have an "exception" attribute anymore.
|
||||
exceptions = super.exceptions_0_10_4;
|
||||
|
||||
# Older compilers need the latest ghc-lib to build this package.
|
||||
hls-hlint-plugin = addBuildDepend super.hls-hlint-plugin self.ghc-lib;
|
||||
|
||||
mmorph = super.mmorph_1_1_3;
|
||||
}
|
||||
|
|
|
@ -123,4 +123,8 @@ self: super: {
|
|||
# ghc versions which don‘t match the ghc-lib-parser-ex version need the
|
||||
# additional dependency to compile successfully.
|
||||
ghc-lib-parser-ex = addBuildDepend super.ghc-lib-parser-ex self.ghc-lib-parser;
|
||||
|
||||
# Older compilers need the latest ghc-lib to build this package.
|
||||
hls-hlint-plugin = addBuildDepend super.hls-hlint-plugin self.ghc-lib;
|
||||
|
||||
}
|
||||
|
|
|
@ -100,10 +100,6 @@ self: super: {
|
|||
url = "https://gitlab.haskell.org/ghc/head.hackage/-/raw/master/patches/regex-base-0.94.0.0.patch";
|
||||
sha256 = "0k5fglbl7nnhn8400c4cpnflxcbj9p3xi5prl9jfmszr31jwdy5d";
|
||||
});
|
||||
syb = appendPatch (dontCheck super.syb) (pkgs.fetchpatch {
|
||||
url = "https://gitlab.haskell.org/ghc/head.hackage/-/raw/master/patches/syb-0.7.1.patch";
|
||||
sha256 = "1407r8xv6bfnmpbw7glfh4smi76a2fc9pkq300c3d9f575708zqr";
|
||||
});
|
||||
|
||||
# The test suite depends on ChasingBottoms, which is broken with ghc-9.0.x.
|
||||
unordered-containers = dontCheck super.unordered-containers;
|
||||
|
|
File diff suppressed because it is too large
Load Diff
|
@ -659,7 +659,9 @@ self: super: builtins.intersectAttrs super {
|
|||
let
|
||||
# spago requires an older version of megaparsec, but it appears to work
|
||||
# fine with newer versions.
|
||||
spagoWithOverrides = doJailbreak super.spago;
|
||||
spagoWithOverrides = doJailbreak (super.spago.override {
|
||||
dhall = self.dhall_1_37_1;
|
||||
});
|
||||
|
||||
# This defines the version of the purescript-docs-search release we are using.
|
||||
# This is defined in the src/Spago/Prelude.hs file in the spago source.
|
||||
|
@ -785,7 +787,7 @@ self: super: builtins.intersectAttrs super {
|
|||
testTarget = "unit-tests";
|
||||
};
|
||||
|
||||
haskell-language-server = overrideCabal super.haskell-language-server (drv: {
|
||||
haskell-language-server = enableCabalFlag (enableCabalFlag (overrideCabal super.haskell-language-server (drv: {
|
||||
postInstall = let
|
||||
inherit (pkgs.lib) concatStringsSep take splitString;
|
||||
ghc_version = self.ghc.version;
|
||||
|
@ -800,7 +802,7 @@ self: super: builtins.intersectAttrs super {
|
|||
export PATH=$PATH:$PWD/dist/build/haskell-language-server:$PWD/dist/build/haskell-language-server-wrapper
|
||||
export HOME=$TMPDIR
|
||||
'';
|
||||
});
|
||||
})) "all-plugins") "all-formatters";
|
||||
|
||||
# tests depend on a specific version of solc
|
||||
hevm = dontCheck (doJailbreak super.hevm);
|
||||
|
|
File diff suppressed because it is too large
Load Diff
|
@ -18,16 +18,6 @@ self: super: {
|
|||
# https://github.com/spacchetti/spago/issues/512
|
||||
spago = self.callPackage ../tools/purescript/spago/spago.nix { };
|
||||
|
||||
# HLS and its fork of ghcide that it uses
|
||||
# both are auto-generated by pkgs/development/tools/haskell/haskell-language-server/update.sh
|
||||
haskell-language-server = self.callPackage ../tools/haskell/haskell-language-server { };
|
||||
hls-hlint-plugin = self.callPackage ../tools/haskell/haskell-language-server/hls-hlint-plugin.nix { };
|
||||
hls-tactics-plugin = self.callPackage ../tools/haskell/haskell-language-server/hls-tactics-plugin.nix { };
|
||||
hls-explicit-imports-plugin = self.callPackage ../tools/haskell/haskell-language-server/hls-explicit-imports-plugin.nix { };
|
||||
hls-retrie-plugin = self.callPackage ../tools/haskell/haskell-language-server/hls-retrie-plugin.nix { };
|
||||
hls-class-plugin = self.callPackage ../tools/haskell/haskell-language-server/hls-class-plugin.nix { };
|
||||
hls-eval-plugin = self.callPackage ../tools/haskell/haskell-language-server/hls-eval-plugin.nix { };
|
||||
|
||||
nix-output-monitor = self.callPackage ../../tools/nix/nix-output-monitor { };
|
||||
|
||||
# cabal2nix --revision <rev> https://github.com/hasura/ci-info-hs.git
|
||||
|
|
|
@ -1,53 +0,0 @@
|
|||
{ mkDerivation, aeson, base, binary, blaze-markup, brittany
|
||||
, bytestring, containers, data-default, deepseq, directory, extra
|
||||
, fetchgit, filepath, floskell, fourmolu, ghc, ghc-boot-th
|
||||
, ghc-paths, ghcide, gitrev, hashable, haskell-lsp, hie-bios
|
||||
, hls-class-plugin, hls-eval-plugin, hls-explicit-imports-plugin
|
||||
, hls-hlint-plugin, hls-plugin-api, hls-retrie-plugin
|
||||
, hls-tactics-plugin, hslogger, hspec, hspec-core
|
||||
, hspec-expectations, lens, lsp-test, mtl, optparse-applicative
|
||||
, optparse-simple, ormolu, process, regex-tdfa, safe-exceptions
|
||||
, shake, lib, stm, stylish-haskell, tasty, tasty-ant-xml
|
||||
, tasty-expected-failure, tasty-golden, tasty-hunit, tasty-rerun
|
||||
, temporary, text, transformers, unordered-containers, with-utf8
|
||||
, yaml
|
||||
}:
|
||||
mkDerivation {
|
||||
pname = "haskell-language-server";
|
||||
version = "0.8.0.0";
|
||||
src = fetchgit {
|
||||
url = "https://github.com/haskell/haskell-language-server.git";
|
||||
sha256 = "0p6fqs07lajbi2g1wf4w3j5lvwknnk58n12vlg48cs4iz25gp588";
|
||||
rev = "eb58f13f7b8e4f9bc771af30ff9fd82dc4309ff5";
|
||||
fetchSubmodules = true;
|
||||
};
|
||||
isLibrary = true;
|
||||
isExecutable = true;
|
||||
libraryHaskellDepends = [
|
||||
base containers data-default directory extra filepath ghc ghcide
|
||||
gitrev haskell-lsp hls-plugin-api hslogger optparse-applicative
|
||||
optparse-simple process shake text unordered-containers
|
||||
];
|
||||
executableHaskellDepends = [
|
||||
aeson base binary brittany bytestring containers deepseq directory
|
||||
extra filepath floskell fourmolu ghc ghc-boot-th ghc-paths ghcide
|
||||
gitrev hashable haskell-lsp hie-bios hls-class-plugin
|
||||
hls-eval-plugin hls-explicit-imports-plugin hls-hlint-plugin
|
||||
hls-plugin-api hls-retrie-plugin hls-tactics-plugin hslogger lens
|
||||
mtl optparse-applicative optparse-simple ormolu process regex-tdfa
|
||||
safe-exceptions shake stylish-haskell temporary text transformers
|
||||
unordered-containers with-utf8
|
||||
];
|
||||
testHaskellDepends = [
|
||||
aeson base blaze-markup bytestring containers data-default
|
||||
directory extra filepath haskell-lsp hie-bios hls-plugin-api
|
||||
hslogger hspec hspec-core hspec-expectations lens lsp-test process
|
||||
stm tasty tasty-ant-xml tasty-expected-failure tasty-golden
|
||||
tasty-hunit tasty-rerun temporary text transformers
|
||||
unordered-containers yaml
|
||||
];
|
||||
testToolDepends = [ ghcide ];
|
||||
homepage = "https://github.com/haskell/haskell-language-server#readme";
|
||||
description = "LSP server for GHC";
|
||||
license = lib.licenses.asl20;
|
||||
}
|
|
@ -1,21 +0,0 @@
|
|||
{ mkDerivation, aeson, base, containers, fetchgit, ghc
|
||||
, ghc-exactprint, ghcide, haskell-lsp, hls-plugin-api, lens, shake
|
||||
, lib, text, transformers, unordered-containers
|
||||
}:
|
||||
mkDerivation {
|
||||
pname = "hls-class-plugin";
|
||||
version = "0.1.0.0";
|
||||
src = fetchgit {
|
||||
url = "https://github.com/haskell/haskell-language-server.git";
|
||||
sha256 = "0p6fqs07lajbi2g1wf4w3j5lvwknnk58n12vlg48cs4iz25gp588";
|
||||
rev = "eb58f13f7b8e4f9bc771af30ff9fd82dc4309ff5";
|
||||
fetchSubmodules = true;
|
||||
};
|
||||
postUnpack = "sourceRoot+=/plugins/hls-class-plugin; echo source root reset to $sourceRoot";
|
||||
libraryHaskellDepends = [
|
||||
aeson base containers ghc ghc-exactprint ghcide haskell-lsp
|
||||
hls-plugin-api lens shake text transformers unordered-containers
|
||||
];
|
||||
description = "Explicit imports plugin for Haskell Language Server";
|
||||
license = lib.licenses.asl20;
|
||||
}
|
|
@ -1,27 +0,0 @@
|
|||
{ mkDerivation, aeson, base, containers, deepseq, Diff, directory
|
||||
, extra, fetchgit, filepath, ghc, ghc-boot-th, ghc-paths, ghcide
|
||||
, hashable, haskell-lsp, haskell-lsp-types, hls-plugin-api
|
||||
, parser-combinators, pretty-simple, QuickCheck, safe-exceptions
|
||||
, shake, lib, temporary, text, time, transformers
|
||||
, unordered-containers
|
||||
}:
|
||||
mkDerivation {
|
||||
pname = "hls-eval-plugin";
|
||||
version = "0.1.0.0";
|
||||
src = fetchgit {
|
||||
url = "https://github.com/haskell/haskell-language-server.git";
|
||||
sha256 = "0p6fqs07lajbi2g1wf4w3j5lvwknnk58n12vlg48cs4iz25gp588";
|
||||
rev = "eb58f13f7b8e4f9bc771af30ff9fd82dc4309ff5";
|
||||
fetchSubmodules = true;
|
||||
};
|
||||
postUnpack = "sourceRoot+=/plugins/hls-eval-plugin; echo source root reset to $sourceRoot";
|
||||
libraryHaskellDepends = [
|
||||
aeson base containers deepseq Diff directory extra filepath ghc
|
||||
ghc-boot-th ghc-paths ghcide hashable haskell-lsp haskell-lsp-types
|
||||
hls-plugin-api parser-combinators pretty-simple QuickCheck
|
||||
safe-exceptions shake temporary text time transformers
|
||||
unordered-containers
|
||||
];
|
||||
description = "Eval plugin for Haskell Language Server";
|
||||
license = lib.licenses.asl20;
|
||||
}
|
|
@ -1,21 +0,0 @@
|
|||
{ mkDerivation, aeson, base, containers, deepseq, fetchgit, ghc
|
||||
, ghcide, haskell-lsp-types, hls-plugin-api, shake, lib, text
|
||||
, unordered-containers
|
||||
}:
|
||||
mkDerivation {
|
||||
pname = "hls-explicit-imports-plugin";
|
||||
version = "0.1.0.0";
|
||||
src = fetchgit {
|
||||
url = "https://github.com/haskell/haskell-language-server.git";
|
||||
sha256 = "0p6fqs07lajbi2g1wf4w3j5lvwknnk58n12vlg48cs4iz25gp588";
|
||||
rev = "eb58f13f7b8e4f9bc771af30ff9fd82dc4309ff5";
|
||||
fetchSubmodules = true;
|
||||
};
|
||||
postUnpack = "sourceRoot+=/plugins/hls-explicit-imports-plugin; echo source root reset to $sourceRoot";
|
||||
libraryHaskellDepends = [
|
||||
aeson base containers deepseq ghc ghcide haskell-lsp-types
|
||||
hls-plugin-api shake text unordered-containers
|
||||
];
|
||||
description = "Explicit imports plugin for Haskell Language Server";
|
||||
license = lib.licenses.asl20;
|
||||
}
|
|
@ -1,26 +0,0 @@
|
|||
{ mkDerivation, aeson, apply-refact, base, binary, bytestring
|
||||
, containers, data-default, deepseq, Diff, directory, extra
|
||||
, fetchgit, filepath, ghc, ghc-lib, ghc-lib-parser-ex, ghcide
|
||||
, hashable, haskell-lsp, hlint, hls-plugin-api, hslogger, lens
|
||||
, regex-tdfa, shake, lib, temporary, text, transformers
|
||||
, unordered-containers
|
||||
}:
|
||||
mkDerivation {
|
||||
pname = "hls-hlint-plugin";
|
||||
version = "0.1.0.0";
|
||||
src = fetchgit {
|
||||
url = "https://github.com/haskell/haskell-language-server.git";
|
||||
sha256 = "0p6fqs07lajbi2g1wf4w3j5lvwknnk58n12vlg48cs4iz25gp588";
|
||||
rev = "eb58f13f7b8e4f9bc771af30ff9fd82dc4309ff5";
|
||||
fetchSubmodules = true;
|
||||
};
|
||||
postUnpack = "sourceRoot+=/plugins/hls-hlint-plugin; echo source root reset to $sourceRoot";
|
||||
libraryHaskellDepends = [
|
||||
aeson apply-refact base binary bytestring containers data-default
|
||||
deepseq Diff directory extra filepath ghc ghc-lib ghc-lib-parser-ex
|
||||
ghcide hashable haskell-lsp hlint hls-plugin-api hslogger lens
|
||||
regex-tdfa shake temporary text transformers unordered-containers
|
||||
];
|
||||
description = "Hlint integration plugin with Haskell Language Server";
|
||||
license = lib.licenses.asl20;
|
||||
}
|
|
@ -1,23 +0,0 @@
|
|||
{ mkDerivation, aeson, base, containers, deepseq, directory, extra
|
||||
, fetchgit, ghc, ghcide, hashable, haskell-lsp, haskell-lsp-types
|
||||
, hls-plugin-api, retrie, safe-exceptions, shake, lib, text
|
||||
, transformers, unordered-containers
|
||||
}:
|
||||
mkDerivation {
|
||||
pname = "hls-retrie-plugin";
|
||||
version = "0.1.0.0";
|
||||
src = fetchgit {
|
||||
url = "https://github.com/haskell/haskell-language-server.git";
|
||||
sha256 = "0p6fqs07lajbi2g1wf4w3j5lvwknnk58n12vlg48cs4iz25gp588";
|
||||
rev = "eb58f13f7b8e4f9bc771af30ff9fd82dc4309ff5";
|
||||
fetchSubmodules = true;
|
||||
};
|
||||
postUnpack = "sourceRoot+=/plugins/hls-retrie-plugin; echo source root reset to $sourceRoot";
|
||||
libraryHaskellDepends = [
|
||||
aeson base containers deepseq directory extra ghc ghcide hashable
|
||||
haskell-lsp haskell-lsp-types hls-plugin-api retrie safe-exceptions
|
||||
shake text transformers unordered-containers
|
||||
];
|
||||
description = "Retrie integration plugin for Haskell Language Server";
|
||||
license = lib.licenses.asl20;
|
||||
}
|
|
@ -1,32 +0,0 @@
|
|||
{ mkDerivation, aeson, base, checkers, containers, deepseq
|
||||
, directory, extra, fetchgit, filepath, fingertree, generic-lens
|
||||
, ghc, ghc-boot-th, ghc-exactprint, ghc-source-gen, ghcide
|
||||
, haskell-lsp, hie-bios, hls-plugin-api, hspec, hspec-discover
|
||||
, lens, mtl, QuickCheck, refinery, retrie, shake, lib, syb, text
|
||||
, transformers
|
||||
}:
|
||||
mkDerivation {
|
||||
pname = "hls-tactics-plugin";
|
||||
version = "0.5.1.0";
|
||||
src = fetchgit {
|
||||
url = "https://github.com/haskell/haskell-language-server.git";
|
||||
sha256 = "0p6fqs07lajbi2g1wf4w3j5lvwknnk58n12vlg48cs4iz25gp588";
|
||||
rev = "eb58f13f7b8e4f9bc771af30ff9fd82dc4309ff5";
|
||||
fetchSubmodules = true;
|
||||
};
|
||||
postUnpack = "sourceRoot+=/plugins/tactics; echo source root reset to $sourceRoot";
|
||||
libraryHaskellDepends = [
|
||||
aeson base containers deepseq directory extra filepath fingertree
|
||||
generic-lens ghc ghc-boot-th ghc-exactprint ghc-source-gen ghcide
|
||||
haskell-lsp hls-plugin-api lens mtl refinery retrie shake syb text
|
||||
transformers
|
||||
];
|
||||
testHaskellDepends = [
|
||||
base checkers containers ghc hie-bios hls-plugin-api hspec mtl
|
||||
QuickCheck
|
||||
];
|
||||
testToolDepends = [ hspec-discover ];
|
||||
description = "Tactics plugin for Haskell Language Server";
|
||||
license = "unknown";
|
||||
hydraPlatforms = lib.platforms.none;
|
||||
}
|
|
@ -1,50 +0,0 @@
|
|||
#!/usr/bin/env nix-shell
|
||||
#!nix-shell -i bash -p cabal2nix jq curl
|
||||
#
|
||||
# This script will update the haskell-language-server derivation to the latest version using
|
||||
# cabal2nix.
|
||||
#
|
||||
# Note that you should always try building haskell-language-server after updating it here, since
|
||||
# some of the overrides in pkgs/development/haskell/configuration-nix.nix may
|
||||
# need to be updated/changed.
|
||||
#
|
||||
# Remember to split out different updates into multiple commits
|
||||
|
||||
set -eo pipefail
|
||||
|
||||
# This is the directory of this update.sh script.
|
||||
script_dir="$( cd "$( dirname "${BASH_SOURCE[0]}" )" >/dev/null 2>&1 && pwd )"
|
||||
|
||||
# ===========================
|
||||
# HLS
|
||||
# ===========================
|
||||
|
||||
# hls derivation created with cabal2nix.
|
||||
hls_derivation_file="${script_dir}/default.nix"
|
||||
|
||||
# This is the current revision of hls in Nixpkgs.
|
||||
hls_old_version="$(sed -En 's/.*\bversion = "(.*?)".*/\1/p' "$hls_derivation_file")"
|
||||
|
||||
# This is the latest release version of hls on GitHub.
|
||||
# Get all tag names, filter to the hls ones (no prefix like 'hls-plugin-api-'),
|
||||
# sort for the latest one and select just that
|
||||
hls_latest_release=$(curl -H "Accept: application/vnd.github.v3+json" https://api.github.com/repos/haskell/haskell-language-server/tags |
|
||||
jq --raw-output 'map(.name) | .[]' |
|
||||
grep '^[0-9]' |
|
||||
sort --version-sort |
|
||||
tail -n1)
|
||||
|
||||
# Use this value instead for the very latest revision
|
||||
# hls_head=(curl --silent "https://api.github.com/repos/haskell/haskell-language-server/commits/master" | jq '.sha' --raw-output)
|
||||
|
||||
hls_new_version=$hls_latest_release
|
||||
|
||||
echo "Updating haskell-language-server from old version $hls_old_version to new version $hls_new_version."
|
||||
echo "Running cabal2nix and outputting to ${hls_derivation_file}..."
|
||||
cabal2nix --revision "$hls_new_version" "https://github.com/haskell/haskell-language-server.git" > "$hls_derivation_file"
|
||||
cabal2nix --revision "$hls_new_version" --subpath plugins/tactics "https://github.com/haskell/haskell-language-server.git" > "${script_dir}/hls-tactics-plugin.nix"
|
||||
for plugin in "hls-hlint-plugin" "hls-explicit-imports-plugin" "hls-retrie-plugin" "hls-class-plugin" "hls-eval-plugin"; do
|
||||
cabal2nix --revision "$hls_new_version" --subpath plugins/$plugin "https://github.com/haskell/haskell-language-server.git" > "${script_dir}/$plugin.nix"
|
||||
done
|
||||
|
||||
echo "Finished."
|
Loading…
Reference in New Issue