haskell-language-server: Remove useless major version aliases

The aliases, like haskell-language-server-8.10 do not get discovered by the hls-wrapper.
Only `haskell-language-server` and e.g. `haskell-languag-server-8.10.7` work.
I got that wrong when introducing those aliases.
This commit is contained in:
Malte Brandy 2021-10-04 21:56:48 +02:00
parent 00627e0ce3
commit c077f5ae57
No known key found for this signature in database
GPG key ID: 226A2D41EF5378C9
2 changed files with 1 additions and 11 deletions

View file

@ -708,14 +708,7 @@ self: super: builtins.intersectAttrs super {
};
haskell-language-server = overrideCabal super.haskell-language-server (drv: {
postInstall = let
inherit (pkgs.lib) concatStringsSep take splitString;
ghc_version = self.ghc.version;
ghc_major_version = concatStringsSep "." (take 2 (splitString "." ghc_version));
in ''
ln -s $out/bin/haskell-language-server $out/bin/haskell-language-server-${ghc_version}
ln -s $out/bin/haskell-language-server $out/bin/haskell-language-server-${ghc_major_version}
'';
postInstall = "ln -s $out/bin/haskell-language-server $out/bin/haskell-language-server-${self.ghc.version}";
testToolDepends = [ self.cabal-install pkgs.git ];
testTarget = "func-test"; # wrapper test accesses internet
preCheck = ''

View file

@ -10,8 +10,6 @@
let
inherit (lib) concatStringsSep concatMapStringsSep take splitString;
getPackages = version: haskell.packages."ghc${version}";
getMajorVersion = packages:
concatStringsSep "." (take 2 (splitString "." packages.ghc.version));
tunedHls = hsPkgs:
haskell.lib.justStaticExecutables
(haskell.lib.overrideCabal hsPkgs.haskell-language-server (old: {
@ -27,7 +25,6 @@ let
let packages = getPackages version;
in [
"haskell-language-server-${packages.ghc.version}"
"haskell-language-server-${getMajorVersion packages}"
];
makeSymlinks = version:
concatMapStringsSep "\n" (x: