depot/third_party/nixpkgs/pkgs/servers/web-apps/livebook/default.nix
Default email 5e9e1146e1 Project import generated by Copybara.
GitOrigin-RevId: 18036c0be90f4e308ae3ebcab0e14aae0336fe42
2023-08-05 00:07:22 +02:00

42 lines
1.1 KiB
Nix

{ lib, beamPackages, makeWrapper, rebar3, elixir, erlang, fetchFromGitHub }:
beamPackages.mixRelease rec {
pname = "livebook";
version = "0.10.0";
inherit elixir;
buildInputs = [ erlang ];
nativeBuildInputs = [ makeWrapper ];
src = fetchFromGitHub {
owner = "livebook-dev";
repo = "livebook";
rev = "v${version}";
hash = "sha256-Bp1CEvVv5DPDDikRPubsG6p4LLiHXTEXE+ZIip3LsGA=";
};
mixFodDeps = beamPackages.fetchMixDeps {
pname = "mix-deps-${pname}";
inherit src version;
hash = "sha256-qFLCWr7LzI9WNgj0AJO3Tw7rrA1JhBOEpX79RMjv2nk=";
};
installPhase = ''
mix escript.build
mkdir -p $out/bin
mv ./livebook $out/bin
wrapProgram $out/bin/livebook \
--prefix PATH : ${lib.makeBinPath [ elixir ]} \
--set MIX_REBAR3 ${rebar3}/bin/rebar3
'';
meta = with lib; {
license = licenses.asl20;
homepage = "https://livebook.dev/";
description = "Automate code & data workflows with interactive Elixir notebooks";
maintainers = with maintainers; [ munksgaard ];
platforms = platforms.unix;
};
}