diff options
author | Sergei Maximov <s.b.maximov@gmail.com> | 2021-11-02 15:57:13 +0300 |
---|---|---|
committer | Raphael Megzari <raphael@megzari.com> | 2021-11-03 08:46:46 +0900 |
commit | 2a9336b426753b1f948bed19c97f07b0f081be46 (patch) | |
tree | 3492627a952697e51ae640133046f13fdade5ff6 /pkgs/development/beam-modules/elixir-ls | |
parent | 45891c5f1c9d03397e8a77a35214a4ce83dc597d (diff) | |
download | nixpkgs-2a9336b426753b1f948bed19c97f07b0f081be46.tar nixpkgs-2a9336b426753b1f948bed19c97f07b0f081be46.tar.gz nixpkgs-2a9336b426753b1f948bed19c97f07b0f081be46.tar.bz2 nixpkgs-2a9336b426753b1f948bed19c97f07b0f081be46.tar.lz nixpkgs-2a9336b426753b1f948bed19c97f07b0f081be46.tar.xz nixpkgs-2a9336b426753b1f948bed19c97f07b0f081be46.tar.zst nixpkgs-2a9336b426753b1f948bed19c97f07b0f081be46.zip |
elixir-ls: build LS using the same Elixir version that is used to run LS
The Elixir LS package in Nixpkgs by default used the latest Elixir version available to compile and run Elixir LS. The user can build a custom Elixir LS package with a different Elixir version: my-custom-elixir-ls = pkgs.elixir-ls.override { elixir = my-custom-elixir; }; But by doing so the user changes only the Elixir version used to run Elixir LS; the Elixir version used to compile Elixir LS doesn't change. As the result, the custom Elixir LS package uses a different Elixir version at runtime than the Elixir version it was compiled with. In order to be able to modify the Elixir version used at build time, I changed `mixRelease` and `fetchMixDeps` to accept `elixir` and `hex` as parameters (defaults to the latest Elixir and Hex packages).
Diffstat (limited to 'pkgs/development/beam-modules/elixir-ls')
-rw-r--r-- | pkgs/development/beam-modules/elixir-ls/default.nix | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/pkgs/development/beam-modules/elixir-ls/default.nix b/pkgs/development/beam-modules/elixir-ls/default.nix index 1385b40fc1f..e0a7cb4e539 100644 --- a/pkgs/development/beam-modules/elixir-ls/default.nix +++ b/pkgs/development/beam-modules/elixir-ls/default.nix @@ -5,6 +5,7 @@ mixRelease rec { pname = "elixir-ls"; version = "0.8.1"; + inherit elixir; src = fetchFromGitHub { owner = "elixir-lsp"; @@ -16,7 +17,7 @@ mixRelease rec { mixFodDeps = fetchMixDeps { pname = "mix-deps-${pname}"; - inherit src version; + inherit src version elixir; sha256 = "sha256-OzjToAg+q/ybCyqzNFk28OBsItjFTbdPi416EPh2qX0="; }; |