Commit 9306ad33 authored by Adrian Dole's avatar Adrian Dole Committed by Vincent Laporte
Browse files

ocamlPackages.ocaml-lsp: 1.14.2 -> 1.16.2

parent 7217de61
Loading
Loading
Loading
Loading
+4 −1
Original line number Diff line number Diff line
@@ -16,7 +16,10 @@ rec {
    sha256 = "sha256-51k+Eo3buzby9cWtbl+/0wbAxa2QSS+Oq0aEao0VBCM=";
  };

  propagatedBuildInputs = [ yojson logs lsp ppx_yojson_conv_lib ];
  lsp_v = lsp.override {
    version = "1.14.2";
  };
  propagatedBuildInputs = [ yojson logs lsp_v ppx_yojson_conv_lib ];

  meta = with lib; {
    description = "LSP server library";
+15 −2
Original line number Diff line number Diff line
{ lib, buildDunePackage, lsp, xdg, re, fiber, makeWrapper, dot-merlin-reader, spawn, ocamlc-loc }:
{ lib
, buildDunePackage
, lsp
, xdg
, re
, fiber
, makeWrapper
, dot-merlin-reader
, spawn
, ocamlc-loc
, odoc-parser
, merlin-lib
}:

buildDunePackage rec {
  pname = "ocaml-lsp-server";
@@ -8,7 +20,8 @@ buildDunePackage rec {
  buildInputs = lsp.buildInputs ++ [ lsp re ]
  ++ lib.optional (lib.versionAtLeast version "1.9") spawn
  ++ lib.optionals (lib.versionAtLeast version "1.10") [ fiber xdg ]
  ++ lib.optional (lib.versionAtLeast version "1.14.2") ocamlc-loc;
  ++ lib.optional (lib.versionAtLeast version "1.14.2") ocamlc-loc
  ++ lib.optional (lib.versionAtLeast version "1.16.2") [ odoc-parser merlin-lib ];

  nativeBuildInputs = [ makeWrapper ];

+30 −16
Original line number Diff line number Diff line
@@ -7,41 +7,55 @@
, fetchurl
, lib
, ocaml
, version ?
    if lib.versionAtLeast ocaml.version "4.14" then
      "1.16.2"
    else if lib.versionAtLeast ocaml.version "4.13" then
      "1.10.5"
    else if lib.versionAtLeast ocaml.version "4.12" then
      "1.9.0"
    else
      "1.4.1"
}:

let params =
  if lib.versionAtLeast ocaml.version "4.14"
  then {
let params = {
  "1.16.2" = {
    name = "lsp";
    minimalOCamlVersion = "4.14";
    sha256 = "sha256-FIfVpOLy1PAjNBBYVRvbi6hsIzZ7fFtP3aOqfcAqrsQ=";
  };
  "1.14.2" = {
    name = "lsp";
    version = "1.14.2";
    minimalOCamlVersion = "4.14";
    sha256 = "sha256-1R+HYaGbPLGDs5DMN3jmnrZFMhMmPUHgF+s+yNzIVJQ=";
  } else if lib.versionAtLeast ocaml.version "4.13"
  then {
  };
  "1.10.5" = {
    name = "jsonrpc";
    version = "1.10.5";
    minimalOCamlVersion = "4.13";
    sha256 = "sha256-TeJS6t1ruWhWPvWNatrnSUWI6T17XKiosHLYizBDDcw=";
  } else if lib.versionAtLeast ocaml.version "4.12"
  then {
  };
  "1.9.0" = {
    name = "jsonrpc";
    version = "1.9.0";
    minimalOCamlVersion = "4.12";
    sha256 = "sha256:1ac44n6g3rf84gvhcca545avgf9vpkwkkkm0s8ipshfhp4g4jikh";
  } else {
  };
  "1.4.1" = {
    name = "jsonrpc";
    version = "1.4.1";
    minimalOCamlVersion = "4.06";
    sha256 = "1ssyazc0yrdng98cypwa9m3nzfisdzpp7hqnx684rqj8f0g3gs6f";
  }
; in
  };
}."${version}"; in

buildDunePackage rec {
  pname = "jsonrpc";
  inherit (params) version;
  inherit version;
  src = fetchurl {
    url = "https://github.com/ocaml/ocaml-lsp/releases/download/${version}/${params.name}-${version}.tbz";
    inherit (params) sha256;
  };

  duneVersion = "3";
  minimalOCamlVersion = "4.06";
  inherit (params) minimalOCamlVersion;

  buildInputs =
    if lib.versionAtLeast version "1.7.0" then
+14 −1
Original line number Diff line number Diff line
@@ -21,11 +21,24 @@
, cmdliner
, ordering
, ocamlformat-rpc-lib
, ocaml
, version ?
    if lib.versionAtLeast ocaml.version "4.14" then
      "1.16.2"
    else if lib.versionAtLeast ocaml.version "4.13" then
      "1.10.5"
    else if lib.versionAtLeast ocaml.version "4.12" then
      "1.9.0"
    else
      "1.4.1"
}:

let jsonrpc_v = jsonrpc.override {
  inherit version;
}; in
buildDunePackage rec {
  pname = "lsp";
  inherit (jsonrpc) version src;
  inherit (jsonrpc_v) version src;
  duneVersion = "3";
  minimalOCamlVersion =
    if lib.versionAtLeast version "1.7.0" then