2021-05-28 09:39:13 +00:00
|
|
|
{ fetchFromGitHub, fetchHex, rebar3Relx, buildRebar3, lib }:
|
2021-05-20 23:08:51 +00:00
|
|
|
let
|
2021-06-01 10:57:12 +00:00
|
|
|
version = "0.16.0";
|
2021-05-20 23:08:51 +00:00
|
|
|
owner = "erlang-ls";
|
|
|
|
repo = "erlang_ls";
|
2021-05-28 09:39:13 +00:00
|
|
|
deps = import ./rebar-deps.nix {
|
|
|
|
inherit fetchHex fetchFromGitHub;
|
|
|
|
builder = buildRebar3;
|
|
|
|
};
|
|
|
|
in rebar3Relx {
|
|
|
|
name = "erlang-ls";
|
2021-05-20 23:08:51 +00:00
|
|
|
inherit version;
|
|
|
|
src = fetchFromGitHub {
|
|
|
|
inherit owner repo;
|
2021-06-01 10:57:12 +00:00
|
|
|
sha256 = "0l09yhj3rsb9zj4cs6a1bcfmi6zbyb3xk1lv494xbyiv5d61vkwm";
|
2021-05-20 23:08:51 +00:00
|
|
|
rev = version;
|
|
|
|
};
|
2021-05-28 09:39:13 +00:00
|
|
|
releaseType = "escript";
|
|
|
|
beamDeps = builtins.attrValues deps;
|
|
|
|
buildPhase = "HOME=. make";
|
2021-05-20 23:08:51 +00:00
|
|
|
installPhase = ''
|
|
|
|
mkdir -p $out/bin
|
|
|
|
cp _build/default/bin/erlang_ls $out/bin/
|
|
|
|
cp _build/dap/bin/els_dap $out/bin/
|
|
|
|
'';
|
|
|
|
meta = with lib; {
|
|
|
|
homepage = "https://github.com/erlang-ls/erlang_ls";
|
|
|
|
description = "The Erlang Language Server";
|
|
|
|
platforms = platforms.unix;
|
|
|
|
license = licenses.asl20;
|
|
|
|
};
|
|
|
|
}
|