-
-
Notifications
You must be signed in to change notification settings - Fork 14.2k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #324678 from adamcstephens/next-ls/init
next-ls: init at 0.23.0
- Loading branch information
Showing
1 changed file
with
54 additions
and
0 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,54 @@ | ||
{ | ||
lib, | ||
|
||
beam_minimal, | ||
fetchFromGitHub, | ||
}: | ||
|
||
let | ||
beamPackages = beam_minimal.packages.erlang_27; | ||
elixir = beamPackages.elixir_1_17; | ||
in | ||
|
||
beamPackages.mixRelease rec { | ||
pname = "next-ls"; | ||
version = "0.23.0"; | ||
|
||
src = fetchFromGitHub { | ||
owner = "elixir-tools"; | ||
repo = pname; | ||
rev = "refs/tags/v${version}"; | ||
hash = "sha256-wTEf0pxVIT7qmPufAN9vGR9rY31kWjNabYZwKe/hkVU="; | ||
}; | ||
|
||
mixFodDeps = beamPackages.fetchMixDeps { | ||
inherit src version elixir; | ||
pname = "next-ls-deps"; | ||
hash = "sha256-4Rt5Q0fX+fbncvxyXdpIhgEvn9VYX/QDxDdnbanT21Q="; | ||
}; | ||
|
||
inherit elixir; | ||
inherit (beamPackages) erlang; | ||
|
||
removeCookie = false; | ||
|
||
# replace installPhase to change release target | ||
installPhase = '' | ||
runHook preInstall | ||
mix release --no-deps-check --path $out plain | ||
makeWrapper $out/bin/plain $out/bin/nextls --add-flags "eval \"System.no_halt(true); Application.ensure_all_started(:next_ls)\"" | ||
runHook postInstall | ||
''; | ||
|
||
meta = with lib; { | ||
homepage = "https://www.elixir-tools.dev/next-ls/"; | ||
changelog = "https://github.com/elixir-tools/next-ls/releases/tag/v${version}"; | ||
description = "The language server for Elixir that just works"; | ||
license = licenses.mit; | ||
mainProgram = "nextls"; | ||
maintainers = [ maintainers.adamcstephens ]; | ||
platforms = beamPackages.erlang.meta.platforms; | ||
}; | ||
} |